Virtual environments break on Homebrew upgrades due to using a Cellar link

On Homebrew, virtual environments created by uv venv reference the Python installation under Cellar in their interpreter symlink and pyvenv.cfg, which has the full downstream version in its path. These virtual environments break when Homebrew upgrades the respective Python package to the next maintenance release. In recent versions of venv and virtualenv, this issue was resolved by using the stable link under $(brew<EMAIL_ADDRESS>instead. For example, on Python 3.11 macOS aarch64 this would be the interpreter in<EMAIL_ADDRESS>This shell session demonstrates the problem:
❯ uv venv
❯ readlink .venv/bin/python
<EMAIL_ADDRESS>❯ grep ^home .venv/pyvenv.cfg
home =<EMAIL_ADDRESS>
When Homebrew upgrades its<EMAIL_ADDRESS>package and cleans up the old installation under Cellar, those references in the virtual environment start to dangle.
For comparison, here's what I get with venv from Homebrew's<EMAIL_ADDRESS>installation:
❯ python3.11 -m venv .venv
❯ readlink .venv/bin/python
python3.11
❯ readlink .venv/bin/python3.11
<EMAIL_ADDRESS>❯ grep ^home .venv/pyvenv.cfg
home =<EMAIL_ADDRESS>
And with virtualenv:
❯ virtualenv --version
virtualenv 20.25.0 from ~/.local/pipx/venvs/virtualenv/lib/python3.12/site-packages/virtualenv/__init__.py
❯ virtualenv .venv
❯ readlink .venv/bin/python
<EMAIL_ADDRESS>❯ grep ^home .venv/pyvenv.cfg
home =<EMAIL_ADDRESS>
Affected platforms: Linux and macOS with Homebrew Python
❯ uv --version
uv 0.1.4
❯ gcc -dumpmachine
arm64-apple-darwin23.2.0

Do you by any chance have a link to the relevant PRs or issues in venv and/or virtualenv?

I don't, but I think venv achieves this by deriving the home key from sys._base_executable, which is the stable path.

The problem is that we're calling canonicalize on the sys.executable.

@konstin -- We may want to revisit this change (https://github.com/astral-sh/uv/issues/965). I think we should only do this (canonicalize) if we're in a virtual environment?

We may want something like...

If we're not in a venv, use sys.executable.
If we are in a venv, resolve symlinks once (not recursively) on sys.executable.

That's closer to virtualenv:
# if we're not in a virtual environment, this is already a system python, so return the original executable
# note we must choose the original and not the pure executable as shim scripts might throw us off
return self.original_executable

I don't know if it's quite relevant but they just fixed a bug by storing the resolved absolute path in the metadata file that is generated for virtual environments: https://github.com/pypa/virtualenv/issues/2682
Also, I know all of you are basically Rust experts, but in case I am reading the source correctly please never ever use canonicalize directly as it is literally (I'm not joking) broken on Windows and will cause all of us bugs and unexpected behavior. Please don't use it. Instead, it's common to use the dunce crate or the normpath crate when you don't want to resolve symlinks. See even Armin talking about it.

Haha. We do use fs::canonicalize but we then strip UNC paths everywhere. (I guess we could use dunce's canonicalize to simplify that process.)

I'd actually expect that virtualenv change to break this case, if I'm reading it correctly.

I don't own a macOS to test that for you unfortunately but that sounds right.

On main, virtualenv uses home =<EMAIL_ADDRESS>So, they might have the same problem @cjolowicz?

\cc @gaborbernat -- it seems like virtualenv on main will resolve symlinks for system Pythons, which seems desirable in some cases (hence the issue in virtualenv) but not in others (hence this issue). I can't tell which is "correct" though.

I do not have a good answer here. 😱

We may want to revisit this change (https://github.com/astral-sh/uv/issues/965). I think we should only do this (canonicalize) if we're in a virtual environment?

Agreed, i think this is better, i'm also thinking about the use case where somebody might have intentional redirects for their python setup.
For the Cellar issue, note that technically different patch versions aren't compatible from a packaging perspective, technically a project could require python_full_version != "3.12.2". In practice projects i've only seen lower bounds for patch version (e.g. >3.8.1), upper or exact bounds would be against how python patch versions are maintained and we're building a more reliable tool by intentionally ignoring this detail.

It would be really nice if this was solved somehow, all my uv venvs break after a minor python update...
Besides the difference in the picked executable symlink as described above, I find it interesting that both tools pick the absolute symlink completely differently:
pip_venv/bin/python@ -> python3.12
pip_venv/bin/python3@ -> python3.12
pip_venv/bin/python3.12@ -><EMAIL_ADDRESS>
uv_venv/bin/python@ -><EMAIL_ADDRESS>uv_venv/bin/python3@ -> python
uv_venv/bin/python3.12@ -> python

FWIW my OCD prefers the pip version, the most specific filename has the absolute symlink (python3.12) instead of uv's least specific (python) 😅
In case it helps anyone here is also the difference between the pyvenv.conf's:
--- pip_venv/pyvenv.cfg 2024-09-13 20:18:47.389618788 +0200
+++ uv_venv/pyvenv.cfg  2024-09-13 20:19:00.968279785 +0200
@@ -1,5 +1,6 @@
-home =<EMAIL_ADDRESS>+home =<EMAIL_ADDRESS>+implementation = CPython
+uv = 0.4.9
+version_info = 3.12.6
 include-system-site-packages = false
-version = 3.12.6
-executable =<EMAIL_ADDRESS>-command =<EMAIL_ADDRESS>-m venv /Volumes/sensitive/src/handmade/0/pip_venv
+relocatable = false

I suggest changing it to resolve symbolic links until a non-venv python is found.

I think at the very least it would be nice to have a flag to force one behavior or the other, but maybe there's a concern of bloating commands with too many switches.

I'm fine to change this but it probably requires 0.5.

I'll look into this as part of v0.5.

So just to summarize current behavior:

python -m .venv: Does not resolve symlinks (seemingly, even if you're creating a venv from within a venv -- at least sometimes).
virtualenv: Does fully resolve symlinks (matches uv's behavior). Older versions of virtualenv do not resolve symlinks, but newer versions do, and so suffer from this same problem.
uv: Fully resolves symlinks.

I don't fully understand the python -m .venv behavior. It may have changed ove rtime. For example, if I create a venv with the Homebrew Python, then create a venv from that venv, I get:
❯ cat .brew1/pyvenv.cfg
home =<EMAIL_ADDRESS>include-system-site-packages = false
version = 3.9.19

❯ cat .brew2/pyvenv.cfg
home = /Users/crmarsh/workspace/uv/.brew1/bin
include-system-site-packages = false
version = 3.9.19

But if I do the same with my non-Homebrew Python, I get:
❯ cat .venv1/pyvenv.cfg
home = /Users/crmarsh/.local/share/rtx/installs/python/3.12.3/bin
include-system-site-packages = false
version = 3.12.3
executable = /Users/crmarsh/.local/share/rtx/installs/python/3.12.3/bin/python3.12
command = /Users/crmarsh/.local/share/rtx/installs/python/3.12.3/bin/python -m venv /Users/crmarsh/workspace/uv/.venv1

❯ cat .venv2/pyvenv.cfg
home = /Users/crmarsh/.local/share/rtx/installs/python/3.12.3/bin
include-system-site-packages = false
version = 3.12.3
executable = /Users/crmarsh/.local/share/rtx/installs/python/3.12.3/bin/python3.12
command = /Users/crmarsh/workspace/uv/.venv1/bin/python -m venv /Users/crmarsh/workspace/uv/.venv2

Ok, if I use Homebrew's 3.12:
❯ cat .venv12-1/pyvenv.cfg
home =<EMAIL_ADDRESS>include-system-site-packages = false
version = 3.12.7
executable =<EMAIL_ADDRESS>command =<EMAIL_ADDRESS>-m venv /Users/crmarsh/workspace/uv/.venv12-1

❯ cat .venv12-2/pyvenv.cfg
home =<EMAIL_ADDRESS>include-system-site-packages = false
version = 3.12.7
executable =<EMAIL_ADDRESS>command = /Users/crmarsh/workspace/uv/.venv12-1/bin/python -m venv /Users/crmarsh/workspace/uv/.venv12-2

So it fully resolves the symlink when inside a virtualenv, and doesn't resolve it when outside a virtualenv.

What we're suggesting is different than all of these: resolve until we see a non-virtualenv. But I think it makes sense.

Ok, I'm guessing that the Homebrew Pythons didn't used to set sys._base_executable? And now it's set to<EMAIL_ADDRESS>so they always use that.

(Gonna put together a table documenting all this.)

Collated here: https://docs.google.com/spreadsheets/d/1Vw5ClYEjgrBJJhQiwa3cCenIA1GbcRyudYN9NwQaEcM/edit?usp=sharing (sorry, the formatting is terrible)

uv's current behavior is closest to the new virtualenv behavior (which also suffers from the problem described in this issue; prior versions did not). The venv behavior is closest to optimal but not quite optimal IMO because it uses sys._base_executable which leads to strange outcomes for the nested virtual environment with Brew.

PR here: https://github.com/astral-sh/uv/pull/8433

Thank you for looking into this. Out of curiosity, what is the use case of

then create a venv from that venv

Admittedly I am a very vanilla venv user, always use a homebrew python (or now uv) to create single simple venv's per projects, or until uv tool install came along, some handmade ~/usr/venvs/... for running python apps not installed with brew (esp after 3.12 python started enforcing not to abuse the system wide site-packages).  btw uv tool install is a real game changer for these and I even uninstalled some brew packages that were lagging a bit behind.
TBH while waiting for this feature to land I was even content just recreating and repopulating the venv's after a python upgrade, it's just so fast from the cache... Although I was a bit surprised that uv venv is a no-questions-asked destructive operation, and an existing .venv means nothing to it 🤣

We refined the behavior a bit in https://github.com/astral-sh/uv/pull/9723.


Cannot login to PartnerCenter for German Cloud ;(

Cannot login to PartnerCenter for German Cloud ;(
Can someone implement that? Please!

Hi @dennings, thank you for opening this issue. With the current design the module does not support the sovereign clouds. Right now we are in the process of planning changes that will make it work with US Government, Germany, and China. I will this issue open until we have implemented the appropriate changes.

Hi @dennings,
We just published a new pre-release version of a new Partner Center PowerShell module that has support for the German cloud. You can find more details about this version at https://github.com/Microsoft/Partner-Center-PowerShell. If you have an opportunity it would be great to get your feedback on the new module.
Since the new version has support for this feature I will be closing this issue now. If you encounter any issue with the new version please open an issue using the appropriate issue tracker.


How do I disable interpolation for Super Nintendo?

I prefer the music have interpolation disabled because it sounds better that way.
How do I disable it?

gme:enableAccuracy(true) maybe?


Feature Request: Selectors

Enable the service to work with selectors instead of elements.

Done in 1.4.0


Add extra dice to Foundry's Dice Configuration menu

This PR adds the extra dice used on DCC to the Dice Configuration menu, which should allows users to choose their preferred rolling method.
It overwrites the original CONFIG.Dice.fulfillment.dice to make sure the dice are displayed in order. Otherwise, d2, d3, d5, etc would show up after d100.
Caveat: Font Awesome has no icons for d7, d14, d16, d24, d30.

Thanks for the PR.
If Foundry supports using images as icons in addition to Font Awesome, I contributed a set of SVG icons for DCC Dice to Dice Tray that we could maybe use.

Foundry supports it. I've tried to add them, but it is a bit tricky since Font Awesome's icons are fonts, so img and div with masks require some new styling, and I wasn't sure you'd want the extra icons for a menu that might be used once or twice.

Thanks! I updated the icons and styled them in our dev-0.46.0 branch, and this will go out with that.


bg-primary classes missing from action buttons?

Discussed in https://github.com/laravel-filament/filament/discussions/911

Originally posted by iancallahan December 17, 2021
First of all, thank you for creating such a great product. I've used Filament to create quick admins for some side projects and it has worked beautifully.
I'm using Filament 2 for the first time on an existing project and I have hit a snag that is probably because I've missed something. It seems that the bg-primary, etc.  classes are missing from action buttons. This leaves me with white text on a white background for all of the action buttons.
I've set up a tailwind theme and that is working fine for the sidebar navigation, but the default action buttons for resources are all showing up this way.
It looks like the second element in the  $buttonClasses array in the button component is not being applied, and I don't know why.

The tailwind config is below, but FWIW this happened right out of the box. I installed Filament with composer and as soon as I added my first model, before registering a theme, I noticed the action buttons were white on white. I pursued tailwind customization thinking that there were no defaults before I realized the tailwind classes were not showing up in the button HTML.
Here's my tailwind.config.js:
const colors = require('tailwindcss/colors')

module.exports =
{content:["app/**/*.php",
"resources/**/*.js",
"resources/**/*.php",
"./vendor/filament/**/*.blade.php"
],
"theme":{"extend":{"colors":{"gray":colors.trueGray,"red":colors.red,"orange":colors.orange,"yellow":colors.yellow,"green":colors.green,"blue":colors.cyan,"purple":colors.violet,"pink":colors.pink,"999999":"#999999","e6e6e6":"#e6e6e6","666666":"#666666","cccccc":"#cccccc","3d3d3d":"#3d3d3d","b3b3b3":"#b3b3b3",danger: colors.rose,
primary: colors.blue,
success: colors.green,
warning: colors.yellow,
}}
},
"variants":{"extend":[]},
plugins: [
    require('@tailwindcss/forms'),
    require('@tailwindcss/typography'),
]}

Hey, I definitely can't replicate this issue. Can you make sure your view cache is clear?

I'm gonna close this, can you create a brand new repo and see if you can replicate the issue. Please send a link here if you can and I'll reopen :)

It turns out I had a $color variable set in a global view composer that was interfering with the Filament color prop. Just mentioning this in case anyone runs into a similar issue.


Scroll behaviour

How can I hide the FSV on recycler view scoll ?

Have you looked at the one of the samples? Please refer to the samples before creating an issue.
More specifically, you want to look at this one. But keep in mind that this is just one way of doing it.
Thanks,
Ari Cheshin


Table2XLog crashes on parsing the timestamps from XLog2Table obtained from receipt log

ERROR Table2XLog Converter 2:3        Execute failed: Text '2011-10-11T13:45:40.276' could not be parsed, unparsed text found at index 0

Hi, to convert the Table2Xlog, you need to set the Date Format to parse the time stamp column. Given the right Date format, it should work.


Allows to retrieve archived projects on a workspace.

This branch allows to retrieve archived projects on a workspace. The endpoint is documented here

Closing the PR. There's another one that is much more complete than mine.


Fix route template path handling

Consider that we store the artifacts on an OS temporary directory (such
as what you would get with mktemp -d or node-tmp) which we can
assume for simplicity purposes to be /tmp/react-static.
In the snippet above, route.template is a path such as
/home/johndoe/site/lib/pages/main.js. Therefore path.relative() will
calculate the path to /home/johndoe/site/lib/pages/main.js from
/tmp/react-static, so the result will be something like
../home/johndoe/site/lib/pages/main.js which makes no sense and will
cause react-static to fail.
What we really intended is path.resolve(), so that the user still gets
/home/johndoe/site/lib/pages/main.js.
Signed-off-by: Juan Cruz Viotti<EMAIL_ADDRESS>

i think you have a better sense of what needs to happen here than i do. leaving this convo for @tannerlinsley

hi everyone! thanks for your PR! there is now a call for maintainers of React Static, please weigh in here: https://github.com/nozzle/react-static/issues/1259

@jviotti can you merge-in master. I think #1219 might have fixed Travis!

@SleeplessByte Done, but I don't think Travis is kicking in anymore

This seems to have introduced a bug where route.template will point to /path/to/site/artifacts/src/containers/Post. Note the artifacts directory in there. I assume the path should be /path/to/site/src/containers/Post.
This can be replicated by starting a fresh project (react-static create) and linking your local react-static (which contains this commit) (cd my-static-site && yarn link react-static). From there running yarn build should error out with the following error:

Module not found: Error: Can't resolve '/my-static-site/artifacts/src/containers/Post'

Unsure of the fix here, and of all the scenarios that should be supported. For me, route.template isn't absolute, it is the exact value as entered in static.config.js.

I figured this wouldn't have been working correctly anyway until #1196 was fixed.
@jviotti can you reproduce the above and fix in a subsequent PR?

Unsure a fix for #1196 will fix this in all scenario - or at least the code here might be simplified otherwise.
Given that path.resolve will resolve from right to left, until an absolute path is made and that config.paths.ARTIFACTS is an absolute path to the artifacts folder, the proposed change will result in either resolving to route.template if it (route.template) is already absolute or to config.paths.ARTIFACTS + route.remplate if it isn't.
$ node
> const path = require('path')

> path.resolve('/my-static-site/artifacts', '/my-static-site/src/containers/Post') # an absolute route, 👍
'/my-static-site/src/containers/Post'
> path.resolve('/my-static-site/artifacts', 'src/containers/Post') # a relative route 👎
'/my-static-site/artifacts/src/containers/Post'

If the fix for #1196 makes route.template always absolute, then could we simplify the change to the following ?
- route.template = slash(path.resolve(config.paths.ARTIFACTS, route.template))
+ route.template = slash(route.template)

If the fix for #1196 makes route.template always absolute, then could we simplify the change to the following ?

I prefer this @nddery. Less resolving and more absolute paths here is probably better.
The problem is that we internally only use relative paths (then it works) and @jviotti only uses absolute paths (then it works) and your case here is absolutely valid and breaks it!

Would it be safe to assume that if route.template is relative, it should resolve against static.conf.js location, and if it's absolute, it should be used as-is ? Something like:
route.template = slash(path.resolve('/path/to/static.conf.js', route.template))

I am a bit weary of saying YES that's SAFE (because we don't have comprehensive tests around these permutations), but I am okay with making that a breaking change. As long as build artifacts can be stored outside of the repo (per OP / @jviotti).

Just to clarify, is the idea to support either relative or absolute path in the static.config.js, or to support only one ? Currently the documentation for documentation for a route object says to use relative paths - if the idea is to switch to absolute paths everywhere, I can open a PR that updates the documentation for the route object as well as all the templates config.

I prefer checking if it's path or root relative, or absolute and internally expand them to all be absolute, if we can. Does that make sense?

That makes sense, thanks for clarifying things for me!

@SleeplessByte re https://github.com/react-static/react-static/pull/1272#issuecomment-519334670 (making this a non-breaking change) the solution proposed above (https://github.com/react-static/react-static/pull/1253#issuecomment-514191625) seems valid to me.
Per the current documentation, route.template should be relative to static.config.js/the root of the project - so by making the change proposed, we'd keep this behavior, as well as support supplying an absolute path. The resulting route.template would however always be absolute, ensuring build artifacts can be stored outside of the repo.

That is perfect.

As a final request @nddery , if you have the time, can you apply that to #1196. It seems that the original author is not around and I'd like to get that moving. In the meanwhile I'll finish up on #1181 and then we're golden for a maintenance release :heart:.
Per our discussions I have also put on the todo list to get starters and examples back up, as well as cleaning up these configurations. The best way forward is probably to always have absolute paths inside react-static core, but allow people to use relative paths in the configuration.

Sounds good - I can update the route.template documentation to indicate we accept either a root relative path or an absolute path if it make sense ? I'll open a new PR as I don't think I can push to #1196. However, I don't think it fixes using a devBasePath, I'll comment over there. I'll try to get that done before leaving today.


For Loops won't compile for Kotlin

JTE version: 3.1.6
Lang: Kotlin 1.9.21
None of the for loops compile. Even if I copy for loop code from the docs, such as the following:
@for(i in 0..10)

i is ${i}

@endfor

My IDE says cannot resolve symbol 'i' and semicolons expected before the 0, after the 0 and after 10. Other than for loops, my JTE code works fine.
EDIT: It seems like JTE only takes Java syntax, not Kotlin, which is what I'm using for this project. Was there something I didn't configure? I'm using it with Javalin.

@MataMercer could it be, that the file ending of your template is .jte?
If you want to use Kotlin expressions instead of Java expressions the templates need to end with .kte.

Yes it is. Oh thank you very much!


Broken File Explorer (Expand All)

If I have my File Explorer open in obsidian with folders and files hidden and expand everything, then it will not display any files or folders. However, If I move the obsidian window to my 32-inch monitor with Full Screen Mode, then it will still display the files and folders but not on a smaller screen or even the 32-inch monitor if it is in (windowed / border) mode.
Is there perhaps a solution to this?

Hey, could you please tell me which Obsidian Version, Plugin Version, Theme, and Operating System you are using :) @Xssistant
Cheers!

Obsidian version: 1.4.14
Hide Folders version: 1.2.0
Theme: Border
Operating System: Windows 11 Pro

Thank you, @JonasDoesThings, for your prompt response and willingness to assist.

The problem is in the style applied to hide the folder, I explain more here.

Should be fixed with version 1.2.1 🥳
Please reopen if it persists.


Bad looking losses

Good Morning!
I am trying to reproduce the very nice results you have in your tutorial but my training do not go as well when I execute python adversarial_autoencoder.py
Here are the losses I obtain:

I tried basically to decrease the learning rate without effect.
Can you help me?
Thanks in advance,
Pierre

Have you modified anything besides the learning rate?
Are you running on GPU or CPU?
Because those two things might have had an effect on why you got those losses...

Hey! Did you try looking at the generated images on Tensorboard?


Build site before packaging into gem

After cloning the Jekyll repository, it builds the documentation site and then puts that into the packaged gem, so no more time and disk space waste.
Fixes #10 :smile:

Thanks! A couple comments. ☝

LGTM.

@jekyllbot: merge

@parkr Thanks for merging!
I'll still try it with all the 3.* versions to see if it doesn't have the conflict about _config.yml and related.


Configurational sampling with non-simulated force field parameters

Description
Starting point for the force field parameter / sequence optimization scheme in which configurational sampling and MBAR are used to evaluate heat capacity (and other properties of interest) for non-simulated systems.
I set up the basic framework for varying force field parameters using updateParametersInContext() function compared to those stored in a cgmodel, and re-evaluating full OpenMM energies for all frames in a replica exchange trajectory set.
The input format for parameter changes is a dictionary of the form param_dict['particlename1_particlename2_..._suffix'] = parameter_value. For example param_dict['bb_bb_bb_bb_torsion_force_constant'] = new_kt_value updates the backbone torsion force constant.
One important difference from some of the existing analysis code is that I organized the energy matrices by [state, evaluated_state, frame] rather than by [replica, evaluated_state, frame] since it was more straightforward to get the evaluated_state energies that way. The trajectories input to the energy evaluation code are the discontinuous state trajectories.
I also made a separate heat capacity calculation function since the inputs are different from the case where we are reading energies from a .nc file.
Todos

[x] Set up input framework for varying different force field parameters
[ ] Set up input framework for varying sequences
[ ] Add testing for varying each possible force field parameter
[ ] Validate results for test cases with full REMD simulation
[ ] Set up optimization framework (with SciPy or custom optimization code if necessary) - this should include determining whether a new full simulation is needed.
[ ] Set up framework for using trajectory sets from multiple simulations
[ ] Use basis functions instead of full OpenMM energy evaluations. We can potentially just store the distance matrices of relevant particles instead of full coordinate trajectories when doing the calculation.

Status

[ ] Ready to go

@mrshirts Here is an example energy array that came out of the eval_energies function for changing sigma_sc from 3.5 to 1.0 A, along with the temperature list corresponding to the states used in the REMD simulation. From these you should be able to run the heat capacity part of the example. Also, I had used frame_begin=300,000 and frame_stride=100 when generating the energy array.
U_array.zip
These came from the last 100ns of a 400ns trajectory (optimized temperature spacing) we used in the cg_openmm paper, so just ignore the log space temperatures defined in the example and use the new ones. Specifically, the simulation force field parameters were:
{
"epsilon_bb": 1.5 kJ/mol,
"epsilon_sc": 5.0 kJ/mol,
"sigma_bb": 2.25 A,
"sigma_sc": 3.5 A,
"k_bond": 15000 kJ/mol/nm^2,
"equil_bond_length": 2.44 A,
"k_angle": 150 kJ/mol/rad^2,
"equil_bond_angle_bb_bb_bb": 105.5 degrees,
"k_torsion": 3 kJ/mol,
"equil_torsion_angle_bb_bb_bb_bb": 16.7 degrees,
"torsion_periodicity": 1,
"n_replica": 12,
"exch_freq": 200,
"coll_freq": 5 / ps
}
I would say the most likely error is how I reduced the energies. The new heat capacity function I made is essentially taken from the code you wrote originally for the energy arrays read in from the .nc files. Another possibility is an issue with the actual force field parameter updates and energy evaluation - I will look into that more if you think the energy array looks ok.

What I think is going on here is you are creating the MBAR object with the resampled energies AS IF they were the sampled energies.  What I'm seeing (I may be misunderstand, is passing in the object U_eval, which contains the energies evaluated with a different Hamiltonian (since there were only 12x12xsamples - if it contained old and new energies, then it would be 12 x 24 x samples (or 24x12xsamples, depends how you organized it), then passed in to initialize the MBAR object.  So then it assumes that the energies you measured were the energies that lead to the given observations.
But you want to initialize the MBAR object with the energies that were actually generated, to find the original probabilities of each sample, then use the computeMultipleExpectations functions to calculate expectations of energies at the reevaluated energies.
Let me know if I misunderstood the code!

You should be able to run it from computeExpectations as well, as long as the array that is passed in has both the new states and the reevaluated states.  Then you will get ntemp*(1+number_reevaluted states) heat capacities out, just have to keep track of the bookkeeping.  You can probably use the same code as before, as long as the u_eval is properly num_temps*(1+num_reevaluated_hamiltonians)(nsamples_per_state) long, and N_k = n_temps[nsamples_per_state] + num_tempsnum_reevaluated+hamiltonians[0] (i.e. zeros for the number of states that are not evaluated).  That way, it will have all the information necessary for the MBAR solutions on JUST the sampled states, and the reevaluated states.
N_effective samples should be of size num_temps*(1+num_reevaluated_hamiltonians), and you want to see for which Hamiltonians it starts to drop lower.
If you use trajectories run with multiple hamiltonians to reweight from, then their N_k's will be nonzero.

What I think is going on here is you are creating the MBAR object with the resampled energies AS IF they were the sampled energies.

Yeah you are right, I see the problem now. I'll start working on fixing this.

Everything seems to be working correctly with the reweighting / energy evaluation here and the new multiple folded state update. The reevaluated energies are as expected now, and match the original reference data when no force field parameters are changed. Issues with seg faults in the tests are also resolved here. I'll merge this huge PR now and document remaining tasks as issues since it's getting hard to keep track of all the changes.


Typo in the link for New England Country Mart.  And http -> https

Thanks! Sorry for the delay, I missed the PR notification.


added TextChangedP to notify when text changed if pumvisible

PR for https://github.com/vim/vim/issues/1691

//cc @shougo @roxma

Codecov Report

Merging #2372 into master will increase coverage by 3.65%.
The diff coverage is 44.44%.

@@            Coverage Diff             @@
##           master    #2372      +/-   ##
==========================================
+ Coverage   70.84%    74.5%   +3.65%
==========================================
  Files          91       91
  Lines      131764   132417     +653
  Branches    29035    29086      +51
==========================================
+ Hits        93351    98655    +5304
+ Misses      38386    33733    -4653
- Partials       27       29       +2

Impacted Files
Coverage Δ

src/fileio.c
75.39% <100%> (+2.55%)
:arrow_up:

src/edit.c
85.23% <28.57%> (+3.38%)
:arrow_up:

src/if_lua.c
54.17% <0%> (+0.55%)
:arrow_up:

src/beval.c
3.66% <0%> (+0.91%)
:arrow_up:

src/regexp_nfa.c
91.2% <0%> (+1.23%)
:arrow_up:

src/main.c
55.42% <0%> (+1.24%)
:arrow_up:

src/libvterm/src/parser.c
62.87% <0%> (+1.28%)
:arrow_up:

src/tag.c
72.29% <0%> (+1.46%)
:arrow_up:

src/if_python3.c
75.8% <0%> (+1.56%)
:arrow_up:

src/json.c
88.19% <0%> (+1.71%)
:arrow_up:

... and 74 more

Continue to review full report at Codecov.

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

@micbou would this be useful in YCM?

Yes, it should be but it will take a while before we can use it given our Vim version requirement.

Prabir Shrestha wrote:

PR for https://github.com/vim/vim/issues/1691

This is missing documentation.
A test would also be useful.
The implementation re-uses last_changedtick_buf and last_changedtick
which are used for TextChangedI, and might cause that event to not be
triggered like it was before.
--
hundred-and-one symptoms of being an internet addict:
29. Your phone bill comes to your doorstep in a box.
/// Bram Moolenaar --<EMAIL_ADDRESS>-- http://www.Moolenaar.net   \
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \
\\  an exciting new programming language -- http://www.Zimbu.org        ///
\\            help me help AIDS victims -- http://ICCF-Holland.org    ///

@brammool

This is missing documentation.

Done. Let me know if I need to add more docs. Also updated syntax file.

A test would also be useful.

I don't see any tests for TextChangedI in test_autocmd.vim. Currently this is how I verified although it would be good to automate this as a test case.
let s:c = 0
function! s:text_changed_i() abort
  call writefile(['I', s:c, b:changedtick], expand('~/Desktop/pum.log'), 'a')
  let s:c += 1
endfunction
function! s:text_changed_p() abort
  call writefile(['P', s:c, b:changedtick], expand('~/Desktop/pum.log'), 'a')
  let s:c += 1
endfunction
autocmd TextChangedI * call s:text_changed_i()
autocmd TextChangedP * call s:text_changed_p()

The implementation re-uses last_changedtick_buf and last_changedtick
which are used for TextChangedI, and might cause that event to not be
triggered like it was before.

Do you have an example for this one?
This is my first vim PR and I'm not familiar with vim source code at all, so if you have a better solution feel free to ignore my PR and write a better solution.

Prabir Shrestha wrote:

@brammool

This is missing documentation.

Done. Let me know if I need to add more docs. Also updated syntax file.

Thanks.

A test would also be useful.

I don't see any tests for TextChangedI in test_autocmd.vim.

This is tested in testdir/test_edit.vim.  However, that's actually for
concealing.

Currently this is how I verified although it would be good to automate
this as a test case.

Yes.  It might be a bit tricky, since the behavior is for interactive
changes.  Check tests for using feedkeys() with "xt" in the second
argument.

let s:c = 0
function! s:text_changed_i() abort
  call writefile(['I', s:c, b:changedtick], expand('~/Desktop/pum.log'), 'a')
  let s:c += 1
endfunction
function! s:text_changed_p() abort
  call writefile(['P', s:c, b:changedtick], expand('~/Desktop/pum.log'), 'a')
  let s:c += 1
endfunction
autocmd TextChangedI * call s:text_changed_i()
autocmd TextChangedP * call s:text_changed_p()

The implementation re-uses last_changedtick_buf and last_changedtick
which are used for TextChangedI, and might cause that event to not be
triggered like it was before.

Do you have an example for this one?
This is my first vim PR and I'm not familiar with vim source code at
all, so if you have a better solution feel free to ignore my PR and
write a better solution.

I think we should not change existing behavior, which is that
TextChangedI would be called at some point when pum_visible() returns
false.  So instead of using last_changedtick for TextChangedP create a
new variable, e.g. last_changedtick_pum, and use that to avoid
triggering the event twice for one change.  However, you probably don't
want to trigger TextChangedP when the popup menu appears, thus you would
check that both last_changedtick differs from the current value and
last_changedtick_pum too.
Also explain this behavior in the docs.  I think it's fine that
TextChangedP and TextChangedI are not symmetrical, since they are for
differen purposes.
--
hundred-and-one symptoms of being an internet addict:
44. Your friends no longer send you e-mail...they just log on to your IRC
channel.
/// Bram Moolenaar --<EMAIL_ADDRESS>-- http://www.Moolenaar.net   \
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \
\\  an exciting new programming language -- http://www.Zimbu.org        ///
\\            help me help AIDS victims -- http://ICCF-Holland.org    ///

Secondly, the TextChangedP autocommand was not called the very first time a popupmenu is displayed, because last_changedtick_pum would have been NULL, so I fixed that as well.

@chrisbra This is the expected behavior based on Bram's comment on https://groups.google.com/forum/#!topic/vim_dev/DrDYKWUeHVY
TextChangedP shouldn't called if pum is not visible. That is what TextChangedI is for. One can easily support listening to both events by using autocmd TextChangedI, TextChangedP * call s:text_changed(). Also should we set v:event so we can check if TextChangedI or TextChangedP was called?

I believe v:event is a neovim specific variable.

I think it was added recently, in patch 8.0.1394, when TextYankPost was implemented.

paging @lifepillar in case this helps mucomplete in any way.

@chrisbra v:event is also supported in vim8. TextYankPost uses it. At least that is what I can see from help in vim8. Or might be we need a special v:event_name that is automatically set for all the commands.

MUcomplete does nothing as long as the pop-up menu is visible, but it needs to know how the pop-up menu is closed. Is TextChangedP triggered by CTRL-E, CTRL-Y and CR?

Thanks, will look at it. However, I won't have time to work on that for at least the next week and even then I will be mostly busy with my real work :(

On Sa, 10 Feb 2018, Bram Moolenaar wrote:

Closed #2372 via 5a093437199001a0d60d8e18e2b9539b99a7757c.

Thanks
Christian
Wußten Sie schon...
... daß vielen Europäern die Sitten und Gebräuche der Orientalen
schleierhaft vorkommen?

Thank! @chrisbra @brammool
Update asyncomplete.vim to use TextChangedP. Works great. https://github.com/prabirshrestha/asyncomplete.vim/pull/49


Truncate long file sample names on Instrument screen

Currently samples with long file names are shown with the full name wrapping to 2nd line instead of being truncated to only show as much as possible on 1 line.

Is there a sample picture of what it looks like when it wraps? I don't have the h/w to see..

thanks for working on the @shockdesign !
Yes here is a photo of a too long sample name on the instrument screen and for extra reference the second photo is from the phrase screen as I just realised that it should also be fixed there too, but I'll open a separate issue for that.

@maks we should be able to close this issue now

@shockdesign yes can do.
Just for future reference, if you add to a PR's description Fixes: #63 then when the PR is merged, it will automatically close the matching issue.


upgrade the developing guide doc and fix some minor changes.

Signed-off-by: Mohit Sharma<EMAIL_ADDRESS>Description
upgrade the developing guide doc and fix some minor changes.
Related Issues
List related issues.
Testing
A few sentences describing what testing you've done, e.g., manual tests, automated tests, deployed in production, etc.
Checklist

kuberne

[ ] I made sure to update CHANGELOG.md.
Remember, the CHANGELOG needs to mention:

Any new features
Any changes to our included version of Envoy
Any non-backward-compatible changes
Any deprecations

[ ] This is unlikely to impact how Ambassador performs at scale.
Remember, things that might have an impact at scale include:

Any significant changes in memory use that might require adjusting the memory limits
Any significant changes in CPU use that might require adjusting the CPU limits
Anything that might change how many replicas users should use
Changes that impact data-plane latency/scalability

[ ] My change is adequately tested.
Remember when considering testing:

LEGACY MODE TESTS DO NOT RUN FOR EVERY PR. If your change is affected by legacy mode, you need
to run legacy-mode tests manually (set AMBASSADOR_LEGACY_MODE=true and run the tests).
(This will be fixed soon.)
Your change needs to be specifically covered by tests.

Tests need to cover all the states where your change is relevant: for example, if you add a behavior that can be enabled or disabled, you'll need tests that cover the enabled case and tests that cover the disabled case. It's not sufficient just to test with the behavior enabled.

You also need to make sure that the entire area being changed has adequate test coverage.

If existing tests don't actually cover the entire area being changed, add tests.
This applies even for aspects of the area that you're not changing – check the test coverage, and improve it if needed!

We should lean on the bulk of code being covered by unit tests, but...
... an end-to-end test should cover the integration points

[x] I updated DEVELOPING.md with any any special dev tricks I had to use to work on this code efficiently.

/asssign

@kflynn can you or ask someone to review this and merge it to master/main branch.


Incomplete filename regex

https://github.com/raix/vscode-perl-debug/blob/7b18c8248bf23720ded62adca01d5a2ea15d9904/src/regExp.ts#L43-L45
Shouldn't filename regex include digits as well? Also it seems that it won't match neither full nor relative paths.
Also it won't match nested namespaces like AA::BB::CC::.

Thanks @otstrel good point - we might also want to be able to convert the match into a valid path for the vs code debugger to reference.

From my experiments it appears that path in debugger output is relative to the current directory of debugger which is probably the same as root parameter of the debug configuration profile.

Interesting, I switched to absolute path's as I remember the PD output varies depending OS and versions. I'm considering creating a "consistency" interface to the PD to help ensure some kind of "contract". (would be easier to write good tests for it)

I have touched this a couple of times in various ways in some of my PRs, it should be a bit better now, though it is most probably not perfect.


Register UbikLoadPack Video Streaming plugin to JMeter-Plugins

Hello @undera ,
This PR is to register our UbikLoadPack Video Streaming plugin so that it's available through jmeter-plugins-manager.
We think we have provided required elements, but let us know if anything is missing.
Kudos to all your OSS work for the JMeter community.
Thanks
Regards

Looks like you forgot to change the descriptor...

Looks like you forgot to change the descriptor...

Bad copy paste, fixed. Sorry

Thanks for merging.
What is the delay for plugin to appear on jmeter-plugins.org ?
Thank you

~30 mins

Thanks, it's available now in JMeter through plugins-manager, but does not appears on website yet when searching for it.
Regards

Probably it was your browser cache at the moment. It works for me now.

Yes it works now.
Thanks


Bump WebChat 9/17/2018

Resolves #675
Resolves #741

bump web-chat
webchat focus styling adjustment
Inspector styling fix (last brace was getting cut off)

@corinagum - The build is broken here. Any ideas?


feat: validate x-sdk-operations extension

Purpose:

ensure the request examples provided using x-sdk-operations extension are good, so they may be utilized properly by tooling that uses x-sdk-operations

Changes:

add custom Spectral rule to validate x-sdk-operations
add custom Spectral function to invoke ajv JSON Schema validator on x-sdk-operations JSON Schema
add JSON Schema representation of x-sdk-operations

Tests:

ensure warnings issued for invalid x-sdk-operations schema

Docs:

document ibm-sdk-operations rule

:tada: This PR is included in version 0.40.0 :tada:
The release is available on:

npm package (@latest dist-tag)
GitHub release

Your semantic-release bot :package::rocket:


Add task to install / configure laptop specific items

Task title pretty much says it all

task added for laptop specific apps, including system task


Frontend-Backend: Image name not being set

Describe the bug
Selecting a single image and specifying the name should upload the image with the given name, but the image uploads with the name of the image
To Reproduce
Steps to reproduce the behaviour:

Go to any project
Click on Project Images
Click Add Image
Choose a single Image
Enter image name different from file name
Click submit
Image uploads with file name, not image name specified

Expected behaviour
Image uploads with image file name
Screenshots
If applicable, add screenshots to help explain your problem.
Desktop (please complete the following information):

OS: Ubuntu 20.04
Browser: Firefox
Version: 98

Additional context
N/A

I am on it.


vendor: update c/image to handle text/plain from registries

Signed-off-by: Antonio Murdaca<EMAIL_ADDRESS>
- What I did
re-vendor c/image to pull in the fix about registries serving (wrongly) text/plain
This also bump to 1.9.6
- How I did it
- How to verify it
- Description for the changelog

@mrunalp PTAL this bump to 1.9.6 as well.

LGTM

/test all

unit test failed in travis.

Looking

/test all

All green here again @mrunalp, let's get this merged to tag


Version sensor with docker source reports "beta"

Home Assistant release with the issue:
every

Operating environment (Hass.io/Docker/Windows/etc.):
every

Component/platform:
version.sensor
Description of problem:
since dockerhub started using a new "beta" tag the version.sensor (with docker source) started reporting "beta" as the current version.

@ludeeus please take a look

@fabaff it's a bug in the lib, I'll fix it and make a release later this weekend.

Ok, thanks for checking.


Dropzone update breaks layout

The new version of dropzone includes major improvements to the previews, but come with breaking changes. Need to update TicketDesk for the new version's changes.

Hi,
I confirm - latest version breaks layout.

Which version of dropzone have correct layout?

Dropzone 3.10.2 worked, dropzone 4.0.x changed their preview layout and styles. Shouldn't be difficult to update ticketdesk to use the new dz preview layout.

I have fixed this issue. please refer  as below code.
css url is wrong
TicketDesk-2.5/TicketDesk.Web.Client/App_Start/Startup.Bundles.cs
Line 39:	.Include("~/Scripts/dropzone/css/dropzone.css", new CssRewriteUrlTransform())
Line 40:	.Include("~/Scripts/dropzone/css/basic.css", new CssRewriteUrlTransform()));
TicketDesk-2.5/TicketDesk.Web.Client/Views/Ticket/New.cshtml    (Line 158 ~ 163)
TicketDesk-2.5/TicketDesk.Web.Client/Views/TicketActivity/_ModifyAttachments.cshtml    (Line 20 ~25)

　　 Drop attachments here, or click to select files.

The element

 should be in
 element.

Thanks for taking care of that Wootz, the changes are now committed.


The "Action" parameter is required for New-ComplianceSecurityFilter (part 2)

Hi there,
Reviewing this article (Set up compliance boundaries for eDiscovery investigations) I see that the instruction and example cmdlets are incomplete. The "Action" parameter is required. I'm recommending that the example cmdlets (and explanations) be updated to include that, for the sake of completeness.
Here's the New-ComplianceSecurityFilter article for reference: New-ComplianceSecurityFilter
The actions available are Export, Preview, Purge, Search, or All.
This is similar to issue 6802 I opened on the Configure permissions filtering for eDiscovery article.
Thanks!
Paul Newell (paulnew)

@PaulRNewell Thank you for your feedback. We have made changes to the document via PR#https://github.com/MicrosoftDocs/microsoft-365-docs/pull/6839
Once the author approves, the changes will be live
Thanks
Sri

closing as per authors' feedback. Thanks


Fix Ruby/Python SDK links in the Readme

GitHub handles the link redirect (you can visit either URL now) so closing this out.


Merge in latest changes; edited error window to say 'Osirium'

Any comment on what it was? I believe some changes could be useful for xrdp.

I think this was an accidental PR.  @speidy and I have been working with them.  We need to split these up into smaller PRs.  Actually, we have already been doing this.  Some already passed review, some in the hopper.  There is more good PRs to come from Osirium but some that we just don't want because they are too specific to Osirium use case.

Thank you for reply. I tried rebasing the PR on top of the devel branch, and I see that most of the remaining patches are for neutrinordp. But still, there are some logic changes that might be useful for xrdp users.

Sorry for the confusion guys. I selected the wrong target branch!


props encoding

props builder needs to encode single quotes correctly.
| inputlookup movies_full_splunk.csv
| rex mode=sed field=prop:name "s/'//g"
| rex mode=sed field=prop:title "s/'//g"
| rex mode=sed field=prop:tagline "s/'//g"
| rex mode=sed field=prop:summary "s/'//g"
input:
{"node_label":"Person","obj_type":"node","props":"{"born":1974,"name":"Jerry O'Connell"}"}
output:
search prop:name="Jerry O'Connell"
MERGE (None:Person { born: '1974', name: 'Jerry O'Connell' }) RETURN ID(None)
ERROR: In reduce(): CypherSyntaxError: ('Invalid input 'n': expected 't/T' (line 1, column 53 (offset: 52))\n"MERGE (n40:Person { born: '1974', name: 'Jerry O'Connell' }) RETURN ID(n40)"\n ^',):
json arrays are incorrectly enclosed in single quotes:
input: "props":"{"apps":["ssl"],"countconn":3322
output:  ...  { apps: '['ssl']', countconn

Fixed with https://github.com/Bamfax/graphee/commit/3c39998119032130dfbbea9405fa8adca4cb572a


wrong linting semicolon when using string literal type in atom

Screenshot

@techird It's possible that the TSLint is using a 1.7.x version of TS which doesn't recognize string literal types correctly. linter-tslint's package.json specifies a TypeScript version of >=1.7.5 which unfortunately will not match prerelease versions like the line of 1.8 nightlies that TypeScript releases. If you swap out the older version of TypeScript for a newer nightly version, does the error go away? Not 100% sure, but I'd look in ~./atom/packages/linter-tslint/node_modules/tslint/node_modules/typescript.

@JKillian That's true! I used to consider that string liternals was supported in 1.7.x.

@techird I just verified that this issue goes away if you're using a TypeScript nightly release. Looks like this isn't a bug then, which is good!

@JKillian I'm getting the missing semicolon error everywhere we have unioned string literal types like in the screenshot.  We're using gulp-tslint 5.0.0 and TS 1.8.3.  How would I determine if the issue is with tslint or gulp-tslint?

Hmm, hard to say, although the root cause sounds like an old version of typescript itself somewhere in the mix. If you run npm ls tslint gulp-tslint typescript what output do you get?

<EMAIL_ADDRESS>G:\snip\main\Library
├──<EMAIL_ADDRESS>├── UNMET PEER DEPENDENCY<EMAIL_ADDRESS>extraneous
└──<EMAIL_ADDRESS>extraneous
npm ERR! peer dep missing<EMAIL_ADDRESS>|| 3.7.0-dev.5 || >=3.8.0-dev || >=3.9.0-dev || >=3.10.0-dev || >=3.11.0-dev, required by<EMAIL_ADDRESS>npm ERR! extraneous<EMAIL_ADDRESS>G:\snip\main\Library\node_modules\typescript

Ah, that explains it! You'll need at least TypeScript 1.8 to have string literal types supported. I'd also recommend upgrading to the most recent version of TSLint, 3.10.1. Lots of good new rules and bugfixes and such, all listed in the CHANGELOG 😄


[VS Code] Agent terminated with exit code:<PHONE_NUMBER> and signal null:

[VS Code] Agent terminated with exit code:<PHONE_NUMBER> and signal null: Failed to load the dll from [C:\Users\PC.vscode\extensions\ms-vsliveshare.vsliveshare-0.3.577\dotnet_modules\hostfxr.dll], HRESULT: 0x80070057The library hostfxr.dll was found, but loading it from C:\Users\PC.vscode\extensions\ms-vsliveshare.vsliveshare-0.3.577\dotnet_modules\hostfxr.dll failed - Installing .NET Core prerequisites might help resolve this problem. http://go.microsoft.com/fwlink/?LinkID=798306
I'm installing .Net SDK Core not fix help me please
Product and Version [VSCode]:
OS Version [Windows 7 Ultimate 64Bit]:
Live Share Extension Version:

Hi,
Do you have KB2533623 installed?
According to Prerequisites for .NET Core on Windows, the error you're seeing may happen if you don't have this KB.

Resolving as a dupe of #854


fixing problems with comments that have % and fixing incompatibility with MySQL

Describe your changes
This PR fixes several problems:

All internal queries now switch between " and backticks depending on the dialect
passing text objects to the execute method to prevent SQLAlchemy from interpreting stuff like %name as query parameter

Issue number
Closes #X
Checklist before requesting a review

[ ] Performed a self-review of my code
[ ] Formatted my code with pkgmt format
[ ] Added tests (when necessary).
[ ] Added documentation in the docstring and changelog (when needed)

:books: Documentation preview :books:: https://jupysql--362.org.readthedocs.build/en/362/

I think I have a lot similar fix in https://github.com/ploomber/jupysql/pull/339/files
But LGTM


KAFKA-14966 - Extract reusable functionality from OffsetFetcher

Initial refactoring for extracting reusable logic from OffsetFetcher into OffsetFetcherUtils. No changes in logic, just moving classes, functions or pieces of logic into OffsetFetcherUtils.
All the functionality moved from OffsetFetcher to the OffsetFetcherUtils is already covered by tests in OffsetFetcherTest and FetcherTest. There were no individual tests for the extracted functions, so no tests were migrated.

LGTM! A couple of things:

Could you attach a Jira Number to the title: KAFKA-abcdefg Extracting reusable functions..
Could you verify if the tests are passing, verbally :)

Thanks both for the comments.
All client test pass (there were only some unrelated broker-side test failures)

Merged into AK on PR-13815


New component hook useDocument()

import { useDocument } from 'vike-react'

function MyComponent() {
  const document = useDocument()
  document.title = 'Awesome Product'
  document.head.add(
    <meta name="description" content="This product helps you with...">
  )
  // ...
}

It's particularly relevant when the data fetching logic is co-located with the component, for example when using Telefunc:
//<EMAIL_ADDRESS>// Environement: client, server

import { loadProductInfo } from './Page.telefunc.js'
import { useDocument, usePageContext, useAsync } from 'vike-react'

function MyComponent() {
  const pageContext = usePageContext()
  const product = useAsync(() => loadProductInfo(pageContext.routeParams.id))
  const document = useDocument()
  document.title = product.name
  document.head.set(
    <meta name="description" content={product.description}>
  )
  // ...
}

//<EMAIL_ADDRESS>// Environement: server

export { loadProductInfo }

async function loadProductInfo(id) {
  const product = await sql.run(`SELECT { name, description } FROM products WHERE id = ${id};`)
  return prodcut
}

Some implementation details: https://github.com/vikejs/vike-react/issues/36#issuecomment-1842870621.
Related: https://github.com/vikejs/vike-react/issues/67.

Closing in favor of https://github.com/vikejs/vike-react/issues/88.

Re-opening because I believe this design to be superior to React 19's approach.

Hello @brillout I've been trying to set the title & meta tags while using vike-react-query. I've tried something similar to your suggestion in #36
injectToStream(
  `<script>document.title = 'someTitleSetByAnyComponent'</script>`,
);

The main issue seems to be (as you commented) that this will not work for SEO/social bots. Setting title & descriptions are specifically useful only for SEO/Social bots. Imagine setting a meta tag like  <meta property="og:image" content={data.imageUrl} /> so that people will see this image on the shared link previews, or providing correct descriptive title and meta tags for search engines.
Is it technically possible to implement useDocument() like you suggested here, but for when streaming is disabled?

@beku8 You can have a look at https://github.com/vikejs/vike-react/pull/108 which is the ongoing implementation of useDocument() among other things. See the changes made to /examples/full/.
It seamlessly works with React Query (because you can use useDocument() after RQ).
Streaming is automatically opted out if a bot is crawling the website, thus SEO & social sharing just works.

@brillout thanks for the response. This looks beautiful, can't wait until it gets released.

This hook would solve a limitation that I am encountering when using react-intl: in order to translate the title tag I need access to the intl context (useIntl), however this context is not available inside +Head.ts.

@FlorianCassayre Makes sense.
In the meantime a possible workaround is to use <Wrapper> to add your useIntl() provider. Although I think the wrapper currently only applies to Page and not to Head, so this would need to be changed e.g. with a new option Wrapper: { value: Component, head: boolean }.

Thanks for the pointer; I'll try that out.
In the meantime this is not a show stopper in my case, but I can totally see a use case for being able to modify the page title inside React components (while still keeping SSG capabilities). This is what sets <title/> (& favicon + language) apart from the other <head/> tags.

https://vike.dev/useConfig
Let us know if anything doesn't work for your use case. We look forward to gathering feedback on the new improvements to head tag management.

Just tried it out (React) and works exactly as advertised, wonderful! This API makes a lot of sense and seems highly flexible. I'm updating my project right away.
Thanks a lot for the solid work!

I'm glad it works out for you!
Definitely let us know if you hit any issues; there is room for improvement which we will be implementing upon user feedback.


New version: TrackerSoftware.PDF-XChangeEditor version <IP_ADDRESS>7

Checklist for Pull Requests

[x] Have you signed the Contributor License Agreement?
[ ] Is there a linked Issue?

Manifests

[x] Have you checked that there aren't other open pull requests for the same manifest update/change?
[x] This PR only modifies one (1) manifest
[x] Have you validated your manifest locally with winget validate --manifest <path>?
[ ] Have you tested your manifest locally with winget install --manifest <path>?
[x] Does your manifest conform to the 1.6 schema?

Note: <path> is the name of the directory containing the manifest you're submitting.

Microsoft Reviewers: Open in CodeFlow

I'm closing this PR because winget bot already merged this exact version from a PR created after this one. The bot even found this PR and marked it as duplicate. This “race” condition created the conflicts, preventing it from automatically merging. There should be some checks to prioritize some PRs over others and automatically closed the rest. Either keep the first, or even better prioritize the bot PRs and if the merge is successful, close all the duplicate PR.


[service-loadbalancer] SSL termination support with HAProxy

This pull request adds support for SSL termination.
Installation instructions

Add annotations to your service:

metadata:
  name: myservice
  annotations:
    serviceloadbalancer/lb.sslTerm: "true"
    serviceloadbalancer/lb.aclMatch: "-i /t1 /t2"
  labels:

Copy your cert and ca for example to: /cfg/ssl/
Update your loadbalancer POD to something like the following

        ports:
        # All http services
        - containerPort: 80
          hostPort: 80
          protocol: TCP
        # ssl term
        - containerPort: 443
          hostPort: 443
          protocol: TCP
        # haproxy stats
        - containerPort: 1936
          hostPort: 1936
          protocol: TCP
        resources: {}
        volumeMounts:
        - mountPath: "/cfg"
          name: pvloadbalancerconf

Add your SSL configuration to loadbalancer.json

    "sslCrt": "/cfg/ssl/server.pem",
    "sslCa": "/cfg/ssl/ca.crt",
    "sslCiphers": "ALL:!HIGH:!LOW:!MD5:!SEED:!EXP:MEDIUM:RC4-SHA verify required"

Define your https-frontend section in template.cfg

frontend httpsfrontend
    mode http
    bind :443 ssl crt {{ .sslCrt }} ca-file {{ .sslCa }} ciphers {{ .sslCiphers }}

{{range $i, $svc := .services.httpsTerm}}
    acl url_acl_{{$svc.Name}} path_beg {{$svc.AclMatch}}
    {{ if $svc.Host }}acl host_acl_{{$svc.Name}} hdr(host) {{$svc.Host}}
    use_backend {{$svc.Name}} if url_acl_{{$svc.Name}} or host_acl_{{$svc.Name}}
    {{ else }}use_backend {{$svc.Name}} if url_acl_{{$svc.Name}}
{{ end }}
{{end}}

Im not that experienced in english to be able to update the readme for instructions. I hope someone can help to finish this up.

NIce! thanks, I'll get to this sometime soon. In the meanwhile @aledbf might have some review comments.

copy your cert and ca for example to: /cfg/ssl/

@remoe this is fine for a first step, but if you're interested in taking this a little further I suggest storing the certs in a secret that is mentioned in the annotation. The loadbalancer would have to read the secrets and load write files.
Simple code to write out pems from key/cert: https://github.com/bprashanth/Ingress/blob/master/examples/https/haproxy/daemonizer.go#L109
And readin secrets should also be easy:
client.Secrets(namespace).Get(name)

You can throw an error if the secret is not a key/cert combo, write out the pem, test the new config (I think haproxy -f) and avoid reloading if the secrets are, say, not in the correct format.

@bprashanth thanks for your hint. I've updated the tests.
Travis fails at "verify-gofmt.sh". But I don't see any output of https://github.com/kubernetes/contrib/blob/master/hack/verify-gofmt.sh#L50
Do you know what is wrong with it?

@remoe you can check the error running ./hack/verify-gofmt.sh from the root of the contrib git directory

@remoe can you make the httpsfrontend conditional?

Add annotations to your service:

Just fyi you can also annotate at runtime via kubectl annotate.

Copy your cert and ca for example to: /cfg/ssl/

You should make this a secret, even if loading them isn't dynamic we shouldn't require users to copy and mount. The kubelet will do that for you. Here's an example of creating/defining a secret in pod spec: https://github.com/kubernetes/kubernetes/blob/master/examples/https-nginx/nginx-app.yaml#L42
Can we actually just get away with duplicating the instruction here to make secret? https://github.com/kubernetes/kubernetes/blob/master/examples/https-nginx/README.md#generate-certificates

Define your https-frontend section in template.cfg

As Manuel suggested we should make this optional

@bprashanth @aledbf , about filtering: do you mean something like this:
{{ if .sslCrt }}
frontend httpsfrontend
...
{{end}}

I found that sslCrt, sslCa and Ciphers are not needed. I will only add sslCert as a pem file, because of:
https://cbonte.github.io/haproxy-dconv/configuration-1.6.html#5.1-crt
If your CA
requires an intermediate certificate, this can also be concatenated into this
file.

And the ciphers can be manually inserted in the template.

@bprashanth when i understand you correctly then you mean one don't need to define any volume on the POD (also no secret volume). One only define a secret name and the load-balancer get the files from this secret. Should this files explicit defined or with a console argument?
But then the load-balancer must write temporary files for HAProxy, right?

Sorry for the misunderstanding. There are 2 scenarios:

ssl termination with lb certs: this needs a secret + secret volumen definition in pod
ssl termination with service certs: this needs an annotation on the service and the loadbalancer needs to read the secrets from the apiserver and write them out to files.

@aledbf I've make httpsfrontend conditional. Do you know why travis not allow my code? I've changed known-flags.txt . Do I need also change the mungegithub/whitelist.txt ?
@bprashanth I've implemented scenario 1. I haven't time for 2, sorry.

go code LGTM but for a few nits, I'm assuming the new template works as intended because I don't know the haproxy cfg format off the top of my head. @aledbf might want to take a final look at the haproxy config changes.

Please also update the README with a section like:
## SSL Termination
1. Add secrets to your loadbalancer pod
2. Annotate a service

That's it right?

@remoe can you provide better defaults? Something like:
in global section
{{ if ne .sslCert "" }}
    ssl-default-bind-ciphers ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-AES256-GCM-SHA384:DHE-RSA-AES128-GCM-SHA256:DHE-DSS-AES128-GCM-SHA256:kEDH+AESGCM:ECDHE-RSA-AES128-SHA256:ECDHE-ECDSA-AES128-SHA256:ECDHE-RSA-AES128-SHA:ECDHE-ECDSA-AES128-SHA:ECDHE-RSA-AES256-SHA384:ECDHE-ECDSA-AES256-SHA384:ECDHE-RSA-AES256-SHA:ECDHE-ECDSA-AES256-SHA:DHE-RSA-AES128-SHA256:DHE-RSA-AES128-SHA:DHE-DSS-AES128-SHA256:DHE-RSA-AES256-SHA256:DHE-DSS-AES256-SHA:DHE-RSA-AES256-SHA:!aNULL:!eNULL:!EXPORT:!DES:!RC4:!3DES:!MD5:!PSK
    ssl-default-bind-options no-tls-tickets
{{ end }}

{{ if ne .sslCert "" }}
frontend httpsfrontend
    mode http
    bind :443 ssl {{ .sslCert }} no-sslv3

    # HSTS (15768000 seconds = 6 months)
    rspadd  Strict-Transport-Security:\ max-age=15768000

{{range $i, $svc := .services.httpsTerm}}
    acl url_acl_{{$svc.Name}} path_beg {{$svc.AclMatch}}
    {{ if $svc.Host }}acl host_acl_{{$svc.Name}} hdr(host) {{$svc.Host}}
    use_backend {{$svc.Name}} if url_acl_{{$svc.Name}} or host_acl_{{$svc.Name}}
    {{ else }}use_backend {{$svc.Name}} if url_acl_{{$svc.Name}}
{{ end }}
{{end}}
{{end}}

Here you can see different examples

@bprashanth @aledbf done.

@bprashanth anything else I can do?

@remoe didn't notice you had uploaded a new patch set. Please squash your commits and rebase, and I'll merge. Also please run  hack/verify-flags-underscore.py locally and see why travis is complaining. Thanks.

@bprashanth about verify-flags-underscore.py, I see the following:
../hack/verify-flags-underscore.py
Found illegal 'flag' usage. If these are false positives you should run `hack/verify-flags-underscore.py -e > hack/verify-flags/exceptions.txt` to update the list.
Ingress/controllers/nginx-third-party/nginx.tmpl:        require("error_page")
Ingress/controllers/nginx-third-party/nginx.tmpl:    error_page 403 @custom_403;
Ingress/controllers/nginx-third-party/nginx.tmpl:    error_page 404 @custom_404;
Ingress/controllers/nginx-third-party/nginx.tmpl:    error_page 405 @custom_405;
Ingress/controllers/nginx-third-party/nginx.tmpl:    error_page 408 @custom_408;
Ingress/controllers/nginx-third-party/nginx.tmpl:    error_page 413 @custom_413;
Ingress/controllers/nginx-third-party/nginx.tmpl:    error_page 500 @custom_500;
Ingress/controllers/nginx-third-party/nginx.tmpl:    error_page 501 @custom_501;
Ingress/controllers/nginx-third-party/nginx.tmpl:    error_page 502 @custom_502;
Ingress/controllers/nginx-third-party/nginx.tmpl:    error_page 503 @custom_503;
Ingress/controllers/nginx-third-party/nginx.tmpl:    error_page 504 @custom_504;

not in my changes ?!

@remoe Hmm, that would mean HEAD is failing. Can you try on your master branch without your changes? and if so, please open a bug or send a pr.

@bprashanth about squash/rebase: Is this now ok?

you actually seem to have 14 commits (or github is confused). We typically take 1 or 2 well defined commits so they're easier to revert. Fyi I generally squash with something like git rebase -i HEAD~14.

@bprashanth sorry. I hope this works now. I don't know how to solve this verify-flags-underscore issue.

@bprashanth sorry. I hope this works now. I don't know how to solve this verify-flags-underscore issue.

ok, this is good. just do as verify-flags-underscore indicates (with the -e option) and I'll file a bug

@bprashanth I've updated the verify-flags exceptions. Is it now ready?

@remoe thanks

@bprashanth @aledbf thanks for your help.


Generate unique short uuid [FEAT]

Is your feature request related to a problem? Please describe.
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
Describe the solution you'd like
A clear and concise description of what you want to happen.
Describe alternatives you've considered
A clear and concise description of any alternative solutions or features you've considered.
Additional context
Add any other context or screenshots about the feature request here.

https://www.npmjs.com/package/short-uuid


Flash Pen for Heads revolutioners

About the PR

Added roundstart item for Headrevs - Flashpen. It's a pen with more powerful lightbulb, which gives rather better stun, slowness and flash.
Why / Balance

New item will be logically better than just a security flash for rp.
No metagaming from Secs, cuz you can insert this pen in ur PDA or don't give it them. Tbh pen a way less suspicious than flash lol.
Some hardcore for Headrev, flashpen only has 3 charges.
Men in black reference.

Technical details
Stun - 2.5s instead of 1.5s;
AoeFlashDuration - 6s instead of 2s;
Range of flash - 5 tiles instead of 7;
Slowness modifier - 0.25 instead of 0.5;
Media

https://github.com/space-wizards/space-station-14/assets/75203942/50d8bd22-8e98-44ae-83d0-746087c8c2be

[x] I have added screenshots/videos to this PR showcasing its changes ingame, or this PR does not require an ingame showcase

Breaking changes

Changelog

:cl: Dezzzix

add: Added roundstart Headrev's Flashpen!

Might want to hide charges info. If you inspect/hold something and see it in decription/ui, then your character knows it, unless sec is supposed to be able to discover it on first arrest which would allow them to check items for tampering?

Might want to hide charges info. If you inspect/hold something and see it in decription/ui, then your character knows it, unless sec is supposed to be able to discover it on first arrest which would allow them to check items for tampering?

I don't have an idea how secs wanna explain why they need to check your pen without metainfo lol. Anyway, I think it'll be better not to hide charge info, cuz of balance(?)

I don't have an idea how secs wanna explain why they need to check your pen without metainfo lol.

You have too much faith that sec will try to justify it (They wont). I like the idea in general though!

Might want to hide charges info. If you inspect/hold something and see it in decription/ui, then your character knows it, unless sec is supposed to be able to discover it on first arrest which would allow them to check items for tampering?

I don't have an idea how secs wanna explain why they need to check your pen without metainfo lol. Anyway, I think it'll be better not to hide charge info, cuz of balance(?)

They check pens because they look for signs of tampering, if tampering is so obvious that inspecting or holding item reveals info, its clearly contraband to be taken away. If you are getting arrested in brig and did not do some really trivial crime that you gonna get very light sentence, you probably should expect full search coming.
Now, if you clearly see its a normal pen(at least from seccie POV) and then your start spamming Z button to use "just in case" its flashpen, epen, ebomb(:trollface:) then its easy ahelp and bwoink, sec needs open uplink, knowledge of such contra IC during round and/or antag cooperation to have justification for checking those.

See closed PRs #22061 and #23451, this appears to be very similar to those.

No way 😨

To follow up on stealth items. This metashield covers them.

So there are stealth items that you can't prove are stealth item unless antags explicitly tells you they are and explains how - thieving gloves. You can't test them as its shielded. Not sure if you can still test them with uplink open, as it was not allowed before so you would need admin stance on this, but as metashield stands I suppose you suddenly know how TGs work as soon as open uplink knowledge is up.
Then we have stealth items that are discovered upon inspection or discovery - your proposal of flash pen, hypopen, epen...
Then we have stealth items that leave clues to find and start looking for them like chameleon TGs, though from sec POV they are only chameleon, not thieving.

So there are stealth items that you can't prove are stealth item unless antags explicitly tells you they are and explains how - thieving gloves.

That makes NO SENSE.
Don't they leave chameleon fibers on anything they touch?

The only problem I see with this is that the pens reveal you as a head rev. Normal flashes still have uses for combat, scientists (and if I remember correctly there was a cargo flash bounty PR) and are just minor contraband. I guess you only use it for the first three conversions and have to get rid of the evidence after, but this causes new ways of metagaming, too. If sec finds a flash pen, the game mode is instantly known. Maybe make it turn into a normal pen or hide the "0 charges" message once it is used up?

chef with a flash is still metagamed regardless if they could have asked sci / stolen it from sec

I think that maybe to avoid metagaming of flash ,it could be done so that each round each player has a very low chance to start with a flash(excepting rev rounds) because if flashes are not illegal then its possible for crewmembers to have them before their shift start.

The only problem I see with this is that the pens reveal you as a head rev.

what if the flash pen was added to traitor uplink too?

The only problem I see with this is that the pens reveal you as a head rev.

what if the flash pen was added to traitor uplink too?

I don't think it's good idea, cuz flash pen very useless for traitors lmao. Only for the lulz? Well....

what if the flash pen was added to traitor uplink too?

It'd be redundant because we already have the flashtern for 2TC at the uplink which serves the exact same niche of being a stealthy antag flash.

I guess you only use it for the first three conversions and have to get rid of the evidence after, but this causes new ways of metagaming, too.

Well-well, i've thinking about adding an auto-recharging of flash 300-600s/1 charge, like in EMAG. It'll make the flash pen less useless, after three conversions, i guess.

oh fu..

Finally fixed

Hey, we had a vote among the maintainers and decided to close this PR. The main reasons mentioned in the discussion were:

This will cause further metagaming through PDA checking.
Finding a flash pen will confirm the game mode, while someone having a normal flash in their inventory still has plausible deniability.
Stealth items currently cause problems rule-wise since they are not marked as contraband, so we don't want to add more of them until a solution is found for this.

Thank you for your contribution.


community-chat-app

Community Chat App Project

[x] Firebase Authentication
[x] Google Sign in
[x] Realtime Data Stream
[x] Implement Security Logic
[ ] Bad Word Filtering

Firebase Authentication

Google signin enabled

Realtime Data stream

Implemented Security Logic


added functionalty requested for Validation.js in TC-21

Styled 'exit' button for Validation in consistent manner with other buttons.
Added setTimeout functionality and utilized useNavigate to redirect to '/'.
Reworked return statement to be conditional depending on whether startTime or endTime is defined.

Merging TC-21 into main and deleting the branch.


secure checksums and urls

It'd be nice to deprecate md5sum to avoid future issues.

BTW, python-pip's previous checksum was wrong. Moreover, both md5sums and sha256sums were present, and both were wrong.


Basics of Tensorflow for begineers

Not relevant here. Either put this in a separate webpage in src.


data preprocess

Hello, could I inquire about how you handle data preprocessing specifically? Is it possible to make the relevant code public?

Hi, the details about the data preprocessing are listed here. We will not release the data processing code temporarily, but we have open-sourced the processed data here.


torusctl: change default ring type of manual-change to ketama

Since default type created by torusctl init is ketama, it is better to use ketama by default in case users run this without type option accidentally.


ERROR  ENOENT: no such file or directory

android
"react-native": "0.43.4",
"react-native-maps":"0.15.3"

Use latest. Try this example: https://github.com/alvelig/react-native-maps-example


Test commit

< PR SPECIFIC CONTENT >

✔ Checklist(s)

[ ] Is the title of the Pull Request correct?
[ ] Is the title of the corresponding issue correct?
[ ] Have you updated the changelog?
[ ] Have you checked to ensure there aren't other open Pull Requests for the same update/change?
[ ] Are you mentioning the issue which this PullRequest fixes ("Fixes...")

🔐 Security
🐞 Bug
✨ Feature
🔧 Refactoring
📚 Documentation

was only created for testing purposes


[KYUUBI #1499] Introduce DataFrameHolder for cli result fetching

Why are the changes needed?

Replace ArrayList with DataFrameHolder
How was this patch tested?

[X] Add some test cases that check the changes thoroughly including negative and positive cases if possible

[ ] Add screenshots for manual tests if appropriate

[X] Run test locally before make a pull request

Codecov Report

Merging #1507 (90a7dd4) into master (73ac1b6) will increase coverage by 0.04%.
The diff coverage is 100.00%.

@@             Coverage Diff              @@
##             master    #1507      +/-   ##
============================================
+ Coverage     59.38%   59.43%   +0.04%
  Complexity      172      172
============================================
  Files           237      238       +1
  Lines         12168    12177       +9
  Branches       1492     1492
============================================
+ Hits           7226     7237      +11
+ Misses         4331     4330       -1
+ Partials        611      610       -1

Impacted Files
Coverage Δ

...e/kyuubi/engine/spark/operation/ExecuteScala.scala
86.36% <100.00%> (ø)

...che/kyuubi/engine/spark/repl/DataFrameHolder.scala
100.00% <100.00%> (ø)

...he/kyuubi/engine/spark/repl/KyuubiSparkILoop.scala
92.85% <100.00%> (+3.96%)
:arrow_up:

Continue to review full report at Codecov.

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

cc @turboFei

thanks, merged to master


Regression in parsing statement with column named 'sequence' in versions 3.2 and 4.0-SNAPSHOT

Describe the bug
Starting from 3.2 release, I'm no longer able to parse a SELECT statement where a column is named sequence.
As far as I can see from previous issues, this is related to SEQUENCE keyword introduced in 3.2, but not added to RelObjectName() production in JSQLParserCC.jit
To Reproduce
Steps to reproduce the behavior:
Example SQL
select a.sequence from all_procedures a

Parsing this SQL using JSqlParser with this statements
import net.sf.jsqlparser.JSQLParserException;
import net.sf.jsqlparser.parser.CCJSqlParserUtil;
import net.sf.jsqlparser.statement.Statement;
import org.junit.jupiter.api.Test;

import static org.junit.jupiter.api.Assertions.assertNotNull;
import static org.junit.jupiter.api.Assertions.assertThrows;

public class TestSqlParser {
  static final String failingQuery = "select a.sequence from all_procedures a";

  @Test
  void testFailingParsing() throws JSQLParserException {
    assertThrows(
        JSQLParserException.class,
        () -> {
          CCJSqlParserUtil.parse(failingQuery);
        });
  }

  @Test
  void testEscapedParsing() throws JSQLParserException {
    final String escaped = failingQuery.replace("a.sequence", "a.\"sequence\"");
    final Statement statement = CCJSqlParserUtil.parse(escaped);
    assertNotNull(statement);
  }
}

Exception
JSQLParserException.class

Expected behavior
This is being parsed fine in 3.1, prior to SEQUENCE keyword introduction
System

Database you are using: Oracle 12c
Java Version: 11
JSqlParser version: 3.2 and 4.0-SNAPSHOT

That is because since version 4 JSqlParser supports a create sequence statement. Therefore sequence is a new keyword. I will make this possible again.


Feature request: Concurrent Promise#reduce

Promise#map is concurrent, but it seems Promise#reduce is not.

Promise#reduce is intentionally not concurrent, I don't see how a concurrent reduce would even work. Of course, no one is stopping you from doing:
var arr = arr.map(somePromiseReturningFn); // all promises generated here
arr.reduce((prev, curPromise) => {

});

Essentially, you can use the native Array#reduce for this.

you cannot have order with concurrency

Is order a must for "reduce" though? For example, if I'm just summing a set of values (common use case for "reduce") resolved by Promises, order is not really relevant.

Right, use Array#reduce then

To your point about summing values, order can make a difference: http://jsbin.com/yokezutuka/1/edit?js,console

Formally, if the operation is associative it can be made concurrent, otherwise it cannot.

Yes, exactly. Unfortunately computer addition isn't associative for many cases (loss of precision, integer overflow) but people often think so since math addition is associative and the notation looks similar.


Added Rule for maximum age of Secrets in SM

I confirm these files are made available under CC0 1.0 Universal (https://creativecommons.org/publicdomain/zero/1.0/legalcode)
Issue #, if available:
Added Rule for maximum age of Secrets in SM
Description of changes:
Added Rule for maximum age of Secrets in SM
Trigger Type: Periodic
Accepted Parameters: max_secret_age_days
Example Values: 1, 2, 3,... default 30
requires boto3 >= 1.9.152, botocore >= 1.12.152, will fail without these library versions as pagination of list_secrets() was not supported with the below libraries included in Lambda as of May 21st 2019
Python 3.7 Lambda includes boto3 "1.9.42"
Python 3.6 Lambda includes boto3 "1.7.74"
You must use a custom deployment package that includes the required boto3 and botocore versions
https://aws.amazon.com/premiumsupport/knowledge-center/build-python-lambda-deployment-package/

************* Module SECRETSMANAGER_MAX_SECRET_AGE_test
SECRETSMANAGER_MAX_SECRET_AGE/SECRETSMANAGER_MAX_SECRET_AGE_test.py:27:8: R1705: Unnecessary "elif" after "return" (no-else-return)
SECRETSMANAGER_MAX_SECRET_AGE/SECRETSMANAGER_MAX_SECRET_AGE_test.py:26:4: R0201: Method could be a function (no-self-use)
SECRETSMANAGER_MAX_SECRET_AGE/SECRETSMANAGER_MAX_SECRET_AGE_test.py:48:8: W1503: Redundant use of assertTrue with constant value True (redundant-unittest-assert)
SECRETSMANAGER_MAX_SECRET_AGE/SECRETSMANAGER_MAX_SECRET_AGE_test.py:6:4: W0611: Unused import mock (unused-import)
SECRETSMANAGER_MAX_SECRET_AGE/SECRETSMANAGER_MAX_SECRET_AGE_test.py:9:0: W0611: Unused ClientError imported from botocore.exceptions (unused-import)
************* Module SECRETSMANAGER_MAX_SECRET_AGE
SECRETSMANAGER_MAX_SECRET_AGE/SECRETSMANAGER_MAX_SECRET_AGE.py:231:4: R1705: Unnecessary "elif" after "return" (no-else-return)
SECRETSMANAGER_MAX_SECRET_AGE/SECRETSMANAGER_MAX_SECRET_AGE.py:249:12: R1714: Consider merging these comparisons with "in" to "status in ('OK', 'ResourceDiscovered')" (consider-using-in)
Your code has been rated at 9.99/10

The RDK generated code causes pylint-github-aws-config-rules to fail?

Unfortunately yes, we need to update the template. I thought we did though. You are using the python3.6 template? @michaelborchert

Unfortunately yes, we need to update the template. I thought we did though. You are using the python3.6 template? @michaelborchert

I'm using 3.7, is the 3.6 template more up-to-date?
I can switch to that and merge my changes to it instead.

Yes! That's must be it. Can you switch to the 3.6, please?

Diffed:
https://github.com/awslabs/aws-config-rdk/blob/master/rdk/template/runtime/python3.7/rule_code.py
https://github.com/awslabs/aws-config-rdk/blob/master/rdk/template/runtime/python3.6/rule_code.py
3.7 is not in sync with 3.6, integrated changes from 3.6 and it's tests which passes pylint-github-aws-config-rules

That should take care of that.
https://github.com/awslabs/aws-config-rdk/pull/179 Sync out of date python3.7 rule_code.py and rule_test.py templates w/3.6 #179


[BUG] Deadlock when exiting Status context

Describe the bug
rich appears to run into a deadlock when exiting from a Status or Live context. This appears to be analogous to #90. The analysis in that issue appears to apply here, as well: The refresh thread is joined under lock. This means that the refresh thread may be waiting for the lock, while the main thread holds the lock waiting for the refresh thread to exit.
To Reproduce
import itertools
import random
import time
from rich.console import Console
from rich.spinner import SPINNERS

console = Console()

for spinner in itertools.cycle(SPINNERS):
    with console.status(spinner, spinner=spinner):
        time.sleep(random.uniform(0, 0.1))
    print("  " + spinner)

Output and traceback:
  dots
  dots2
  dots3
  dots4
  dots5
  dots6
  dots7
  dots8
  dots9
  dots10
  dots11
  dots12
  dots8Bit
  line
  line2
^CTraceback (most recent call last):
  File "/home/cjolowicz/Code/github.com/willmcgugan/rich/repro.py", line 14, in <module>
    time.sleep(random.uniform(0, MAX_DURATION))
  File "/home/cjolowicz/Code/github.com/willmcgugan/rich/rich/status.py", line 101, in __exit__
    self.stop()
  File "/home/cjolowicz/Code/github.com/willmcgugan/rich/rich/status.py", line 94, in stop
    self._live.stop()
  File "/home/cjolowicz/Code/github.com/willmcgugan/rich/rich/live.py", line 160, in stop
    self._refresh_thread.join()
  File "/usr/lib64/python3.9/threading.py", line 1033, in join
    self._wait_for_tstate_lock()
  File "/usr/lib64/python3.9/threading.py", line 1049, in _wait_for_tstate_lock
    elif lock.acquire(block, timeout):
KeyboardInterrupt

Platform
What platform (Win/Linux/Mac) are you running on? What terminal software are you using?

Linux (Fedora 33)
Python 3.9.1
Kitty 0.19.3

Diagnose
❯ poetry run python -m rich.diagnose
╭───────────────────────────────────────────────────── <class 'rich.console.Console'> ──────────────────────────────────────────────────────╮
│ A high level console interface.                                                                                │
│                                                                                │
│     color_system = 'truecolor'                                                                                │
│         encoding = 'utf-8'                                                                                │
│             file = <_io.TextIOWrapper name='<stdout>' mode='w' encoding='utf-8'>                                                          │
│ is_dumb_terminal = False                                                                                │
│       is_jupyter = False                                                                                │
│      is_terminal = True                                                                                │
│   legacy_windows = False                                                                                │
│          options = ConsoleOptions(legacy_windows=False, min_width=1, max_width=141, is_terminal=True, encoding='utf-8', justify=None,     │
│                    overflow=None, no_wrap=False, highlight=None)                                                                          │
│           record = False                                                                                │
│         safe_box = True                                                                                │
│             size = ConsoleDimensions(width=141, height=77)                                                                                │
│        soft_wrap = False                                                                                │
│           stderr = False                                                                                │
│            style = None                                                                                │
│         tab_size = 8                                                                                │
│            width = 141                                                                                │
╰───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯
❯ poetry run python -m rich._windows
platform="Linux"
WindowsConsoleFeatures(vt=False, truecolor=False)
❯ poetry run pip freeze | grep rich
rich @ file:///home/cjolowicz/.cache/pypoetry/artifacts/98/1d/5d/051dc7cc639b654ddd087351e285d0c10d3755f771a13803e0860b239a/rich-9.5.1-py3-

Looks like the following change fixes the deadlock:
diff --git a/rich/live.py b/rich/live.py
index 0c01a36..db714c3 100644
--- a/rich/live.py
+++ b/rich/live.py
@@ -157,7 +157,11 @@ class Live(JupyterMixin, RenderHook):
             try:
                 if self.auto_refresh and self._refresh_thread is not None:
                     self._refresh_thread.stop()
-                    self._refresh_thread.join()
+                    self._lock.release()
+                    try:
+                        self._refresh_thread.join()
+                    finally:
+                        self._lock.acquire()
                     self._refresh_thread = None
                 # allow it to fully render on the last even if overflow
                 self.vertical_overflow = "visible"

Looks like the following change fixes the deadlock:
diff --git a/rich/live.py b/rich/live.py
index 0c01a36..db714c3 100644
--- a/rich/live.py
+++ b/rich/live.py
@@ -157,7 +157,11 @@ class Live(JupyterMixin, RenderHook):
             try:
                 if self.auto_refresh and self._refresh_thread is not None:
                     self._refresh_thread.stop()
-                    self._refresh_thread.join()
+                    self._lock.release()
+                    try:
+                        self._refresh_thread.join()
+                    finally:
+                        self._lock.acquire()
                     self._refresh_thread = None
                 # allow it to fully render on the last even if overflow
                 self.vertical_overflow = "visible"

Thanks for the report. You're absolutely right about the deadlock. Fixed in 9.8.2

Thanks for the report. You're absolutely right about the deadlock. Fixed in 9.8.2


Bump 2.x to 2.15.0

Description
Bump 2.x to 2.15.0
Related Issues
N/A

Check List

[X] New functionality includes testing.

[X] All tests pass

[X] New functionality has been documented.

[X] New functionality has javadoc added

[X] Failing checks are inspected and point to the corresponding known issue(s) (See: Troubleshooting Failing Builds)
[X] Commits are signed per the DCO using --signoff
[X] Commit changes are listed out in CHANGELOG.md file (See: Changelog)
[X] Public documentation issue/PR created

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

Thanks @reta!

Pending:

https://github.com/opensearch-project/opensearch-build/pull/4674

Publish 2.15.0 snapshot:

https://build.ci.opensearch.org/job/publish-opensearch-min-snapshots/1239/console


Added react-medium-image-zoom

@alexvarko, a resized image opens on zoom instead of the full original image. Can we change it somehow?


[Sema] Record opaque type decls for type reconstruction after creation instead of in the parser.

Now that opaque type decl creation is a request, there's no reason to record opaque types in the parser instead of in OpaqueResultTypeRequest.

@swift-ci please smoke test


Missing dependency in example_requirements.txt

Not a bug, not a deal-breaker, but just to note that the following notebook makes use of tqdm which currently is missing from the example_requirements.txt:
examples/submissions/1_Santanilla_Nanomole_HTE/
Alternatively, the notebook could contain !pip install ... ?

Thanks; I'll fix this!

Fixed in https://github.com/open-reaction-database/ord-schema/pull/619 (back in January)


organization_settings: Move setting to new line.

Fix #20415

Testing plan:
Manually
GIFs or screenshots:

Hi @alya. Kindly review.

Looks good to me! @timabbott ready for your review.

@Manan-Rathi since this PR has been dormant for a while, I would be happy to take over and resolve the related issue.
Is it alright with you?


added parse options

This allows passing options such as:

Default parsing
Detailed processing record
Incomplete parsing
etc.

Currently I am moving all classes to a package so I can upload it to python packet index and also add a new feature.
I am working on develop branch and merge it to master branch after finishing work.
Please see also at https://github.com/FraMuCoder/PyClASVi/tree/develop
It already contains your first pull request.
Your new pull request is still based on master branch, so it is hard to merge it with current develop branch.
Can you please try to provide you changes based on current develop branch?


kickstart: init at 0.4.0

Description of changes
This PR packages the tool: https://github.com/Keats/kickstart
Things done

Built on platform(s)

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

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

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

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

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

[x] Fits CONTRIBUTING.md.

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

1 package built:

kickstart


Image Size Problem

Hi,
We are using Google Efficient Det for object detection and it returns images with different size(for ex. 150x200). We have two problems.

After image resize process with function read_image_file, we realized that program does not compute as expected since image is corrupted(or simply resized). Is there a way to compare images with different sizes rather than resizing it? We may did some implementation issues so we are going to share code snippet.

`def image_comparison(image_pil,image_no):
# image_pil -> pillow object that is detected by google efficient det.
global threshold # 0.0798
image_temp = image_pil
image_file_path_list = updateImageFiles() # Function that returns images in given directory

# Since read_image_file reads from path we resize our image_pil here
image_array = np.array(image_temp) # RGB
image_array = cv2.resize(image_array, input_shape[:2][::-1])

if evaluation_only:
    if len(image_file_path_list) == 0:
        image_pil.save("/home/mertcan/Desktop/checkPath/" + str(image_no) + ".jpg", 'JPEG')
        image_file_path_list = updateImageFiles()
        return -1;       # Nothing in directory just add given image

    image_content_list = [
        read_image_file(image_file_path, input_shape)
        for image_file_path in image_file_path_list
    ]

    image_content_list.append(image_array)
    image_content_array = preprocess_input(np.array(image_content_list))

    image_features = inference_model.predict(image_content_array,batch_size=batch_size)

    distance_matrix = test_evaluator_callback.compute_distance_matrix(
        query_image_features=[image_features[-1]], # Last image is query image
        gallery_image_features=image_features[:-1], #[image_features[i] for i in range(len(image_features)-1)],
        metric="cosine",
        use_re_ranking=use_re_ranking)

    min=100 # Minumim similarity ratio
    index=-1 # To return image index.

    for i in range(len(distance_matrix[0])):
        if(distance_matrix[0][i]<min):
            min , index = distance_matrix[0][i] , i

    if(min>threshold):
        image_pil.save("/home/mertcan/Desktop/checkPath/" + str(image_no) + ".jpg", 'JPEG')
        return -2
    else:
        print("Return index:", index)
        return index

`
2) We had some unexpected results even at moments when resizing wasn't too important. We want to explain this with images.
first image -> a frame in video
second image -> image that is stored in directory
third image -> query image

Computation of distance matrix between images is: 0.09410524 ( We think that is caused by size or color differences of the images)

Hi,
Thanks for your interest in our work.

When training those person re-identification models, we have experimented with other strategies which make the samples have the same shape during the training procedure, e.g., applying zero padding. However, using direct resizing achieves the best performance on the test set. Ideally, one should use the same preprocessing pipeline in the training and test procedures.
Alternatively, you could modify the inference_model so that it accepts samples with arbitrary shapes. Note that those models are fully-convolutional. Just change the height and width to None, and feed the test samples one by one (i.e., the batch size is one). Please find the following code snippet that I have used in other projects. You might need to make modifications as I haven't  tested it on this model:

def modify_input_shape(model, input_shape, custom_objects=None):
    if np.array_equal(model.input_shape[1:], input_shape):
        return model
    vanilla_weights = model.get_weights()
    model._layers[0]._batch_input_shape = (None, *input_shape)  # pylint: disable=protected-access
    model = model_from_json(json_string=model.to_json(),
                            custom_objects=custom_objects)
    model.set_weights(vanilla_weights)
    return model

What's your concern regarding the distance between the samples provided by you? Is it too high? It's better to validate the model in a query-gallery setting, just like a standard person re-identification benchmark. This is inherently a ranking problem, and the model is not making binary decisions.

All the best.
Xingyang Ni

Hi,
Thanks for your interest in our work.

When training those person re-identification models, we have experimented with other strategies which make the samples have the same shape during the training procedure, e.g., applying zero padding. However, using direct resizing achieves the best performance on the test set. Ideally, one should use the same preprocessing pipeline in the training and test procedures.
Alternatively, you could modify the inference_model so that it accepts samples with arbitrary shapes. Note that those models are fully-convolutional. Just change the height and width to None, and feed the test samples one by one (i.e., the batch size is one). Please find the following code snippet that I have used in other projects. You might need to make modifications as I haven't  tested it on this model:

def modify_input_shape(model, input_shape, custom_objects=None):
    if np.array_equal(model.input_shape[1:], input_shape):
        return model
    vanilla_weights = model.get_weights()
    model._layers[0]._batch_input_shape = (None, *input_shape)  # pylint: disable=protected-access
    model = model_from_json(json_string=model.to_json(),
                            custom_objects=custom_objects)
    model.set_weights(vanilla_weights)
    return model

What's your concern regarding the distance between the samples provided by you? Is it too high? It's better to validate the model in a query-gallery setting, just like a standard person re-identification benchmark. This is inherently a ranking problem, and the model is not making binary decisions.

All the best.
Xingyang Ni