text:
auto close QR code after receiving or update it to match the current receiving address

When on the receive screen you can click to increase the size of the QR code in a new window. After receiving, the receive screen advances to the next address, but the old QR code is still showing.
Please make sparrow either close the larger QR code window or make it show the next address to match the main receive screen.

Sparrow will now close the dialog when the address updates. 33d9f260. Added some UI to make the dialog easier to find at the same time.

authors: AndySchroder craigraw

repo: sparrowwallet/sparrow


text:
Feature Request: Support for importing wallet.dat files?

I know it's a PIA, but it also such a PIA to access ancient wallet.dat files already that a fully-featured wallet like sparrow supporting it would be a god send.
Not saying you should let people make wallet.dat files, just import and extract keys from then.
I do recovery for people sometimes and no one except bitcoin core seems to support this ancient file format. I know there's more advanced tools to extract keys from them, but having a clean interface that supports it would be lovely.
Cheers guys. Great wallet.

Unfortunately this is probably not going to happen - it would mean supporting outdated versions of BerkeleyDB across all platforms, not to mention handling the outdated ways that Bitcoin Core used to store keys (not HD wallets). I know it's a PITA, sorry!

Unfortunately any reading of the file would require BerkeleyDB - it is a binary format native to that library.

source: gharchive/issue

authors: craigraw jsgalt

license_type: permissive

license_source: github-api


text:
3d voxel rendering

Currently we display 3d voxel data (such as segmented geomery, species concentrations from simulations, etc) in the GUI as a 2d x-y slice with a slider to choose the z coordinate:

This is robust and fast, but it would be nice to also have the option to display some kind of 3d render of this information.
For example here are two views of the same data using matplotlib, on the left voxels (but only outer faces shown), on the right superimposed x-y images stacked in the z-direction:

Or with napari:

Not so many c++ libraries for this:

Qt3d

would be ideal in terms of integration
but a naive attempt with many cuboid meshes didn't scale beyond a handful of voxels: https://github.com/lkeegan/qt3d_experiments

https://vtk.org/

has qt integration
probably the one to try first if Qt3d is not sufficient

https://github.com/datoviz/datoviz

looks nice but uses Vulkan instead of opengl
no qt integration yet

license: MIT


text:
Quick Fixes (DOC-1088)

Contributions: We are not currently taking public contributions - see our contributions policy. However, we are accepting issues and we do want your feedback.

Description
Small fixes for docs - adding missing links, correcting wrong links and typos etc. See DOC-1088 for a list of fixes made.
Primary reviewers
@ElleEss @NotRobSheridan

@ElleEss Have all your requested changes been made? Would be great to get this in.

Thanks a lot Ieva for making these updates. I looked through Laura's feedback and believe everything is now addressed - we can always re PR later, but think it's important to get this in now as we have kicking off on the GDK template doc and example project (adding simplayers) so merging will avoid bad merge conflicts later. Also this has fixes on our 1.0 experience that are important to get in for new users.

source: gharchive/pull-request

authors: ernopp ieva-improbable m-samiec

repo: spatialos/UnrealGDK


text:
NuGet availability

Can you make Direct3DHook available on NuGet?

@Asconius currently the library is written as a starting point for further work. There are a number of things that would need to be done to make this a more reusable library in the form of a NuGet.
I'll leave this here as a request, but I think a fair bit of repo reorganisation is required first.

authors: Asconius spazzarama

license: mit

license_source: bigquery


text:
Update source and target java version to 11

Fixes #76
Signed-off-by: Gary O'Neall gary@sourceauditor.com

Hi all,
Why not use the release property instead now that you require Java 11?

Why not use the release property instead now that you require Java 11?

@garydgregory I saw the suggestion in the Maven documentation, but when I added the property, it didn't build.
I replaced the previous source and target properties with:
<maven.compiler.release>11</maven.compiler.release>

and got the following error:
[ERROR] Source option 5 is no longer supported. Use 7 or later.
[ERROR] Target option 5 is no longer supported. Use 7 or later.
[ERROR] -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException

I'm probably doing something rather stupid - let me know if you see what the issue may be.

I fixed the above issue by using the latest version of the maven compiler plugin.

authors: garydgregory goneall

repo: spdx/spdx-maven-plugin


text:
Generated Markdown contains multiple consecutive blank lines

Currently, Markdown generated from the templates contains multiple consecutive blank lines, which is against markdownlint rule MD012.
Coordinated adjustments among template files can avoid this undesirable outcome.
Proposal:

Remove explicit multiple consecutive blank lines from every files
Remove blank lines at the start and the end of the content of block meta in every templates that extend from page.md.j2, as necessary blank lines are for the blocks is already in page.md.j2.
Remove blank lines at the end of the content of block meta in every templates that extend from page.md.j2, as necessary blank lines are for the blocks is already in page.md.j2.
Remove blank lines 22 and 23 in page.md.j2 to leave no blank lines between block metadata and block extra.

This is to avoid two consecutive blank lines at the end of the file, the case that block extra is empty.
Because of this, it has to maintain that the first line of block extra in every templates has to be a blank line (which all of them already are), so that content from block metadata and block extra will be separated by exactly one blank line, if block extra is exist.

Carefully, with if condition block in mind, maintain one blank line before and after a heading/a list. To maintain M022 and MD032.

I see no issue with having the generated mkdocs input that no one ever sees not conform to some random linter.
I definitely prefer having whitespace that helps editing and understanding in the templates.

authors: bact zvr

repo: spdx/spec-parser


text:
Maximum & minimum does not work at parameters

Description
limit:
  description: The number of items to return
  in: query
  name: limit
  required: true
  schema:
    type: integer
    minimum: 1
    maximum: 1000

Expected behaviour
Numbers above and below 1 and 1000 must to decline by server
Actual behaviour
They are being accepted
Steps to reproduce
Just try to validate integer by maximum and minimum at parameters
Additional info:
Output of the commands:

Python 3.7.2
Version: 2018.0.dev1

Hey @lovesuper - we use https://github.com/p1c2u/openapi-spec-validator in order to validate incoming data against the spec.
Can you file a ticket there?

hey @lovesuper  - I misread you ticket - This is not related to openapi-spec-validator and is actually related to jsonschema. Is maximum in the Draft4 jsonschema spec?

fixed in v2.2.0 a0ac0fd

Fixed

authors: RobbeSneyders dtkav hamid914 lovesuper

repo: spec-first/connexion


text:
Account Selection dropdown should include account email in addition to name

Usecase:
Where a user has multiple accounts on a server all using their same proper name, having sight of the email used for each account would enable users to determine the correct account to use correctly

https://github.com/specklesystems/speckle-qgis/commit/f7e9457246ec067bc9651ed4a5f8fe06ab4df4fb

https://github.com/specklesystems/speckle-qgis/commit/f7e9457246ec067bc9651ed4a5f8fe06ab4df4fb

authors: KatKatKateryna jsdbroughton

repo: specklesystems/speckle-qgis


text:
fix (navisworks): CNX-8305 - IDE0005

Remove unused using statements

I think you missed one, CI is still failing for Navis.

Navis builds

repo: specklesystems/speckle-sharp


text:
Unable to perform transaction in test

Hello dear xUnitRevit-Team,
i get an exception when trying to run a test that uses the temporary transaction trick (https://thebuildingcoder.typepad.com/blog/2012/10/the-temporary-transaction-trick-for-gross-slab-data.html). The Revit API then (of course) complains that the model must not be manipulated from outside.
Did somebody find a solution to deviate this problem? Might there be a possibility with xru.RunInTransaction?
Thanks a lot!

@LotharTUM thanks for reporting this!
Do you have a snippet of code to reproduce the issue?

Hello Matteo!
The function i want to test is this:

static public PlanarGeometry GetWallContour(Wall wall, Document doc)
{
IList inserts = wall.FindInserts(true, true, true, true);
Transaction temporaryTransaction = new Transaction(doc);
temporaryTransaction.Start("Temporary - only to get gross area");
foreach (ElementId insertId in inserts) {doc.Delete(insertId);}
doc.Regenerate();
IList wallFaceReference = HostObjectUtils.GetSideFaces(wall, ShellLayerType.Exterior);
PlanarFace face = doc.GetElement(wallFaceReference.First())
.GetGeometryObjectFromReference(wallFaceReference.First()) as PlanarFace;
IList wallFaceEdges = face.GetEdgesAsCurveLoops();
double grossArea = ExporterIFCUtils.ComputeAreaOfCurveLoops(wallFace);
PlanarGeometry wallGeometry = new PlanarGeometry(wallFaceEdges.First(), face.FaceNormal, grossArea);
temporaryTransaction.RollBack();
return wallGeometry;
}

Thanks a lot!

Hey @LotharTUM , thanks for the additional info and feedback!
I've added a xru.Run() method that will allow you to have more control over the transaction, you can see the updated example:
https://github.com/specklesystems/xUnitRevit/blob/master/SampleLibrary/SampleTest.cs#L42-L70

Thanks Matteo!

authors: LotharTUM teocomi

repo: specklesystems/xUnitRevit


text:
API

Effects.

$(target|el, handler) - query elements list in current context.
mod(selector, handler) - attach selector observer [within the current context].
html`...content`  - make sure the content exists in the current context.
state(obj?) - set state values associated with the current context.
local - persisted state.
query - state reflected in history.

Ok, API is stabilized.

repo: spectjs/spect


text:
[Bug]:  Pretrain wav2vec: No such file or directory: 'wav2vec2-base/train.csv'`**

Describe the bug
I run sbatch command and I have the .py and .yaml files in the location: /home/flck/
but I have the audio data files in directory location: /l/users/flck/new_dataset/train/clean
speechbrain generates a directory in location /home/flck/ because that is where I launch the sbatch command
as you can see I would like to pretrain on another dataset called in directory "new_dataset" not librispeech. The dataset consists of .flac files all in directory:  /l/users/flck/new_dataset/train/clean
this is the exact command:
python /home/flck/sb_w2v_pretrain/train_sb_wav2vec2.py /home/flck/sb_w2v_pretrain/hparams/wav2vec2_base.yaml --find_unused_parameters --max_grad_norm 0.0
FileNotFoundError: [Errno 2] No such file or directory: 'wav2vec2-base/train.csv'
'wav2vec2-base' directory (that was generated) contains:

env.log
hyperparams.yaml
log.txt
save
train_sb_wav2vec2.py

where save directory is empty
Expected behaviour
pretraining wav2vec model on speechbrain dataset
To Reproduce
yaml file:
data_folder: /l/users/flck/peoples_speech_/train/clean
output_folder: wav2vec2-base #/l/users/flck/peoples_speech_/train/wav2vec2-base
save_folder: !ref <output_folder>/save          #"./wav2vec2-pretrained-demo"
Logging file for every N optimizer steps (many lines)
train_steps_log: !ref <output_folder>/train_steps_log.txt
Logging file per epoch
train_stage_log: !ref <output_folder>/train_stage_log.txt
train_splits: ["train-clean-100"]
dev_splits: ["dev-clean"]
test_splits: ["test-clean"]
train_csv: !ref <output_folder>/train.csv
valid_csv: !ref <output_folder>/dev-clean.csv
Versions

transformers version: 4.29.2
Platform: Linux-5.4.204-ql-generic-12.0-19-x86_64-with-glibc2.31
Python version: 3.9.7
Huggingface_hub version: 0.14.1
Safetensors version: not installed
PyTorch version (GPU?): 1.11.0 (False)
Tensorflow version (GPU?): not installed (NA)
Flax version (CPU?/GPU?/TPU?): not installed (NA)
Jax version: not installed
JaxLib version: not installed
Using GPU in script?:
Using distributed or parallel set-up in script?:

Relevant log output
speechbrain.core - Beginning experiment!
speechbrain.core - Experiment folder: wav2vec2-base
speechbrain.core - Exception:
Traceback (most recent call last):
  File "/home/flck/sb_w2v_pretrain/train_sb_wav2vec2.py", line 394, in <module>
    main()
  File "/home/flck/sb_w2v_pretrain/train_sb_wav2vec2.py", line 374, in main
    train_dataset, valid_loader, train_loader_kwargs = dataio_prepare(hparams)
  File "/home/flck/sb_w2v_pretrain/train_sb_wav2vec2.py", line 258, in dataio_prepare
    train_data = sb.dataio.dataset.DynamicItemDataset.from_csv(
  File "/home/flck/.conda/envs/vcheckworthy/lib/python3.9/site-packages/speechbrain/dataio/dataset.py", line 365, in from_csv
    data = load_data_csv(csv_path, replacements)
  File "/home/flck/.conda/envs/vcheckworthy/lib/python3.9/site-packages/speechbrain/dataio/dataio.py", line 129, in load_data_csv
    with open(csv_path, newline="") as csvfile:
FileNotFoundError: [Errno 2] No such file or directory: 'wav2vec2-base/train.csv'

Why is it skipping https://github.com/speechbrain/speechbrain/blob/develop/recipes/LibriSpeech/self-supervised-learning/wav2vec2/train_sb_wav2vec2.py#L359 ? Have you set skip_prep = True ?

I tried
python /home/flck/sb_w2v_pretrain/train_sb_wav2vec2.py /home/flck/sb_w2v_pretrain/hparams/wav2vec2_base.yaml --find_unused_parameters --max_grad_norm 0.0 --skip_prep=False
same error:
"FileNotFoundError: [Errno 2] No such file or directory: 'wav2vec2-base/train.csv'"

I did, nothing changed

ok I will try on my side.

On my side it does enter in the Data_preparation step see:
speechbrain.core - Beginning experiment!
speechbrain.core - Experiment folder: wav2vec2-base
librispeech_prepare - Data_preparation...
librispeech_prepare - Creating csv lists in  wav2vec2-base/train-clean-100.csv...
I did the following:
python3 /speechbrain/recipes/LibriSpeech/self-supervised-learning/wav2vec2/train_sb_wav2vec2.py /speechbrain/recipes/LibriSpeech/self-supervised-learning/wav2vec2/hparams/wav2vec2_base.yaml --data_folder=path_of_my_data
Could you please restart with a fresh yaml file and just override the data folder through the CLI?

thank you, @Adel-Moumen
I will download 350 and 500 train splits too. Because I think that is why it is not working.
In the meantime can you let me know if there is a way for speechbrain to train wav2vec with a new dataset instead of librispeech?

I think this is the problem!! You should remove the 350 and 500 keys from train_splits: ["train-clean-100", "train-clean-360", "train-other-500"] if you wants to only train on train 100... :-)

Yes, first follow this tutorial to grasp a better understanding of what we are doing https://colab.research.google.com/drive/1aFgzrUv3udM_gNJNUoLaHIm78QHtxdIz?usp=sharing then you will have to write your own data prepare file. You can start from the LibriSpeech Wav2vec finetuning one and then modify it to suits your needs.

Please close this issue if your problem is solved (this is important for us as we have many issues to monitor)

I did remove the 350 and 500:
train_splits: ["train-clean-100"] #["train-clean-100", "train-clean-360", "train-other-500"]
dev_splits: ["dev-clean"]
test_splits: ["test-clean"]
but
error is "FileNotFoundError: [Errno 2] No such file or directory: 'wav2vec2-base/train.csv'"
so I guess it only works if all three are there

Nop/

python3 ../speechbrain/recipes/LibriSpeech/self-supervised-learning/wav2vec2/train_sb_wav2vec2.py ../speechbrain/recipes/LibriSpeech/self-supervised-learning/wav2vec2/hparams/wav2vec2_base.yaml --data_folder=/local_disk/idyie/amoumen/LibriSpeech --train_splits=["train-clean-100"]
Outputs:
speechbrain.core - Beginning experiment!
speechbrain.core - Experiment folder: wav2vec2-base
librispeech_prepare - Data_preparation...
librispeech_prepare - Creating csv lists in  wav2vec2-base/train-clean-100.csv...
100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████▉| 28538/28539 [02:07<00:00, 223.41it/s]
librispeech_prepare - wav2vec2-base/train-clean-100.csv successfully created!
librispeech_prepare - Creating csv lists in  wav2vec2-base/dev-clean.csv...
100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████▉| 2702/2703 [00:15<00:00, 173.67it/s]
librispeech_prepare - wav2vec2-base/dev-clean.csv successfully created!
librispeech_prepare - Creating csv lists in  wav2vec2-base/test-clean.csv...
100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████▉| 2619/2620 [00:09<00:00, 284.91it/s]
librispeech_prepare - wav2vec2-base/test-clean.csv successfully created!
speechbrain.dataio.dataio - wav2vec2-base/train.csv is created.
speechbrain.dataio.sampler - Batch quantisation in latent space
speechbrain.dataio.sampler - DynamicBatchSampler: Generating dynamic batches
speechbrain.core - Info: debug arg overridden by command line input to: False
speechbrain.core - Info: debug_batches arg overridden by command line input to: 2
speechbrain.core - Info: debug_epochs arg overridden by command line input to: 2
speechbrain.core - Info: debug_persistently arg overridden by command line input to: False
speechbrain.core - Info: device arg overridden by command line input to: cuda:0
speechbrain.core - Info: data_parallel_backend arg overridden by command line input to: False
speechbrain.core - Info: distributed_launch arg overridden by command line input to: False
speechbrain.core - Info: distributed_backend arg overridden by command line input to: nccl
speechbrain.core - Info: find_unused_parameters arg overridden by command line input to: False
speechbrain.core - Info: auto_mix_prec arg from hparam file is used
speechbrain.core - Info: max_grad_norm arg from hparam file is used
speechbrain.core - Info: optimizer_step_limit arg from hparam file is used
speechbrain.core - Info: tqdm_colored_bar arg overridden by command line input to: False
speechbrain.core - 90.9M trainable parameters in W2V2Brain
speechbrain.utils.checkpoints - Would load a checkpoint here, but none found yet.
speechbrain.utils.epoch_loop - Going into epoch 1
So it does works to only specify train-clean-100

maybe it is because I am working from two locations:

home/user (where script is and from where I launch)
l/user  (where my data is)

(btw I tried with fairseq too and there I did not face the issue of creating a new script for a new dataset. The only problem I faced there was to load the checkpoint model after 12 hours with "fairseq-hydra-train" command. )

I dont think so. My data are located in a specific disk while the training files are in another one. I don't understand what changes from your environment and mine tbh. It should work out of the box...

It works now. Thank you, @Adel-Moumen for all the quick responses.

authors: Adel-Moumen flckv

repo: speechbrain/speechbrain


text:
Update HISTORY.md

Updated history with coconut release content.

why do only the first part have working links to the PRs and the rest dont?

can you elaborate a bit more about the new features so readers will have a general idea what its doing without going into the links

also, we should stick with the rocksdb way of only including issues that affect the user

authors: Yuval-Ariel bosmatt

repo: speedb-io/speedb


text:
Add Renderers And Notion as Blog CMS

I have added Notion renderers and Notion blog starter kits that use the frontend framework to make static web pages.
I named the section 'Renderer' and 'Notion as Blog CMS', but I don't know if this is appropriate.
Please let me know if the section's location is not appropriate.
Thanks.

Added. Not sure I like the organization of the new sections, but I'm not gonna prematurely optimize. I'm planning to add a load of tools soon so I'll reorganize then. Thank you very much @younho9!

repo: spencerpauly/awesome-notion


text:
Pick name for crate

YACC Belongs to Yet Another Compiler Compiler, acc is already a crate.

CTTC -- Compile-Time Terminal Colors

repo: spenserblack/acc


text:
Add blackfriday/ExtensionsMask option.

Added new config option blackfriday/extensionsmask to
disable unwanted default extensions.

Merged in 3596b1b

authors: bep glabra


text:
lack of multi-page navigation

Multi-page sphinx documents when rendered in Confluence do not have the Previous and Next page navigation links (am I missing a configuration setting?) nor is it possible to have a sidebar ToC to support in-page navigation (Confluence limitation). I have documented the concerns more fully here on RtD and here in Confluence in the actual sphinx doc that I used to test confluencbuilder. (Thanks to @jdknight for fixing one of the issues I hit with curly-braces in headings being interpreted as macros -- see #161).
If you were able to get navigation links working, that would somewhat mitigate the Confluence sidebar ToC limitation. If Atlassian were to fix #43090 that would be huge.

(see also #214)

The initial implementation for next/previous pages have been merged into master (see #214) and will be available next release.

repo: sphinx-contrib/confluencebuilder


text:
feat(pg): Support new networks

Purpose
Adds logic to automatically update drippie configuration when necessary.
Adds support for:

Celo + testnet
Kava + testnet
Scroll + testnet
EVMOS + testnet
Moonbeam, Moonriver, Moonbase Alpha (testnet)
OKX Chain

Note that I am intentionally not adding support for:

OKX Chain testnet: I was not able to find a reliable RPC endpoint for this network with support for all the rpc methods we need. We'd have to run our own node to support this network.
Heco or it's testnet: I was not able to find a way to bridge to this network or an exchange which I can legally access and that would sell me their token in a reasonable amount of time. I was also not able to find any node providers for this network. Honestly, this network seems defunct. Their git repo hasn't seen a single commit in 2 years and their TVL is lower than the amount their bridge was hacked for in November. I think the hack may have killed them.
Rootstock or its testnet: This is due to ethers failing to reliably estimate the gas limit for action execution transactions. We could totally support them, but it would require more effort to investigate the issue and implement a solution that works reliably.
Fuse sparknet (testnet): Ethers does not accurately estimate gas limit which causes transactions to revert. This may be related to the issue with Rootstock.

Todo before release

[x] Find node providers for all networks
[x] Get reasonable quantity of tokens on all networks
[x] Determine which networks are supported etherscan or blockscout and get API keys
[x] Deploy and verify contracts on all networks
[x] Test the deploy command on all networks
[x] Test deploying via the website on all networks

Notes
I've created a ticket to address some issues I noticed with the deploy command separately.

Just realized that this PR doesn't update the sphinxConfig.testnets/mainnets field in the configuration options doc

Just realized that this PR doesn't update the sphinxConfig.testnets/mainnets field in the configuration options doc

good catch

repo: sphinx-labs/sphinx


text:
ios 11以下 左边往右偏移了位置 右边往左偏移了位置

UIBarButtonItem * backItem = [UIBarButtonItem itemWithTarget:nil action:nil image:[UIImage imageNamed:@"back_Image"]];
self.navigationItem.leftBarButtonItem = backItem;
这是创建按钮的代码 iOS11的位置正常，   11以下 我用iOS 9 的试了下 位置就不正常了

已修复,之前改出的问题, 最新版1.0.6

authors: ArthurCL spicyShrimp

repo: spicyShrimp/UINavigation-SXFixSpace


text:
Night CI 2023-04-21: Failed

action url: https://github.com/spidernet-io/spiderpool/actions/runs/4761147960

The same issue as #1682.

authors: iiiceoo weizhoublue

repo: spidernet-io/spiderpool


text:
TypeError: unsupported operand type(s) for -: 'str' and 'str'

Hello
I'm using the following veriosn of mysql-statsd on CentOS 6.
# pip list | grep mysql-statsd
mysql-statsd (0.1.4)

When I run mysql_statsd I got the following error after few seconds
# mysql_statsd --config /root/statsd-mysql/mysql-statsd.conf -d --foreground
('status.aborted_connects', '1', 'd')
('status.com_delete', '707701', 'd')
('status.com_insert', '707700', 'd')
('status.com_insert_select', '0', 'd')
...
...
...
('status.threads_created', '90', 'd')
('status.threads_running', '17', 'g')
('variables.max_connections', '151', 'g')
Exception in thread Thread-1:
Traceback (most recent call last):
  File "/usr/lib64/python2.6/threading.py", line 532, in __bootstrap_inner
    self.run()
  File "/usr/lib/python2.6/site-packages/mysql_statsd/thread_mysql.py", line 149, in run
    self._run()
  File "/usr/lib/python2.6/site-packages/mysql_statsd/thread_mysql.py", line 92, in _run
    rows = self._preprocess(check_type, column_names, cursor.fetchall())
  File "/usr/lib/python2.6/site-packages/mysql_statsd/thread_mysql.py", line 131, in _preprocess
    return executing_class.process(rows, *extra_args)
  File "/usr/lib/python2.6/site-packages/mysql_statsd/preprocessors/innodb_preprocessor.py", line 66, in process
    self.process_line(line)
  File "/usr/lib/python2.6/site-packages/mysql_statsd/preprocessors/innodb_preprocessor.py", line 207, in process_line
    self.tmp_stats['unpurged_txns'] = self.tmp_stats['innodb_transactions'] - self.make_bigint(innorow[6], innorow[7])
TypeError: unsupported operand type(s) for -: 'str' and 'str'

Hi @Alexhha, thanks for your bugreport. I've tried to add a quick fix, and hope to be able to make a new release for this tomorrow. You can see the fix here: https://github.com/spilgames/mysql-statsd/pull/36
If you would like to help me test this, could you apply the fix on the machine where the problem is occuring?
That means editing /usr/lib/python2.6/site-packages/mysql_statsd/preprocessors/innodb_preprocessor.py line 207 and incorporate the fix proposed in the pull request like this:
int(self.tmp_stats['innodb_transactions'])

Now I'm getting
self.tmp_stats['unpurged_txns'] = int(self.tmp_stats['innodb_transactions']) - self.make_bigint(innorow[6], innorow[7])
TypeError: unsupported operand type(s) for -: 'int' and 'str'

authors: Alexhha thijsdezoete

repo: spilgames/mysql-statsd


text:
Behavior change between Jena 3.0.1 and 3.16.0-SNAPSHOT

After long overdue upgrade from Jena 3.0.1 to 3.16.0-SNAPSHOT, some SPIN constraint validation-based tests started failing. Where 3.0.1 produced no violations, 3.16.0-SNAPSHOT produces violations like Attribute spin:body : [0,1] not only for user data, but also for instances from the internal SPIN vocabulary, such as spin:ConstructTemplates.
I have managed to isolate a standalone example: https://github.com/namedgraph/spinrdf-test
Toggle SPINRDF versions in the POM (which depend on Jena 3.16.0-SNAPSHOT and  3.0.1 respectively) and the test will either fail or succeed:
https://github.com/namedgraph/spinrdf-test/blob/08da50a593a8bfb01a7768227dbb04ba0333bb37/pom.xml#L28
The test uses the following query:
SELECT  ?this ?predicate ?objCount ?minCount ?maxCount
WHERE
  { ?this  a                     ?TYPE_CLASS
      { BIND(<http://spinrdf.org/spl#objectCount>(?this, ?predicate)
AS ?objCount)
        FILTER ( bound(?minCount) && ( ?objCount < ?minCount ) )
      }
    UNION
      { BIND(<http://spinrdf.org/spl#objectCount>(?this, ?predicate)
AS ?objCount)
        FILTER ( bound(?maxCount) && ( ?objCount > ?maxCount ) )
      }
    UNION
      { FILTER bound(?valueType)
        ?this  ?predicate  ?value
        FILTER ( ! <http://spinrdf.org/spl#instanceOf>(?value, ?valueType) )
      }
  }

and binding: ( ?predicate, spin:body )( ?comment, "the body of the Template" )( ?minCount, 0 )( ?TYPE_CLASS, spin:Template )( ?maxCount, 1 )
I'd like to understand why there's a difference in evaluation and how to fix it (assuming 3.0.1 behavior is correct). Since SPINRDF code hasn't changed (there are commits in between but they do not touch any code), this leads me to believe it's because of a change in Jena. Might have to do with the evaluation of SPIN "functions" spl:objectCount() and spl:instanceOf(). Help pinning this down would be appreciated.

The version that we bundle with TopBraid (which uses a recent Jena version) has this body for spl:Attribute
CONSTRUCT {
    _:b0 a spin:ConstraintViolation .
    _:b0 spin:violationRoot ?this .
    _:b0 spin:violationPath ?predicate .
}
WHERE {
    FILTER (((bound(?minCount) && (spl:objectCount(?this, ?predicate) < ?minCount)) || (bound(?maxCount) && (spl:objectCount(?this, ?predicate) > ?maxCount))) || EXISTS {
        {
            FILTER bound(?valueType) .
        } .
        ?this ?predicate ?value .
        FILTER (!spl:instanceOf(?value, ?valueType)) .
    }) .
}

Thank you Holger.
Would it be possible to get an update of all the vocabularies? As long as there were no incompatible changes. That would be great help.

I'll email them to you. No idea what might break etc.

@HolgerKnublauch what about a spl:Attribute query which does not use any SPIN functions? Would that improve the Jena/SPARQL compatibility and/or break some things on your end?
From what I could reconstruct by expanding the functions such as spl:instanceOf, I got this query:
PREFIX  xsd:  <http://www.w3.org/2001/XMLSchema#>
PREFIX  rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX  rdf:  <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
ASK
WHERE
  {   { FILTER bound(?minCount)
        { SELECT  (count(*) AS ?cardinality)
          WHERE
            { ?this  ?predicate  ?object }
          HAVING ( ?cardinality < ?minCount )
        }
      }
    UNION
      { FILTER bound(?maxCount)
        { SELECT  (count(*) AS ?cardinality)
          WHERE
            { ?this  ?predicate  ?object }
          HAVING ( ?cardinality > ?maxCount )
        }
      }
    UNION
          {
            ?this  ?predicate  ?object
            FILTER ( isURI(?object) || isBlank(?object) )
            FILTER bound(?valueType)
            FILTER NOT EXISTS {
                ?object a ?class .
                ?class (rdfs:subClassOf)* ?valueType
            }
        UNION
          {
            ?this  ?predicate  ?object
            FILTER isLiteral(?object)
            FILTER bound(?valueType)
            BIND(datatype(?object) AS ?datatype)
            FILTER ( ! ( ?datatype IN (?valueType, rdfs:Literal) || ( ( ! bound(?datatype) || ?datatype = rdf:langString ) && ?valueType = xsd:string ) ) )
          }
      }
  }

If it produces equivalent results, then in principle it could be used? It passes my very rudimentary test suite:
https://github.com/AtomGraph/spinrdf/blob/sparql-based/src/test/java/org/spinrdf/constraints/ConstraintTest.java
/cc @afs

I believe I had to rely on functions here because that would give me control over the execution order. I think it would otherwise first evaluation the inner SELECTs before the FILTER.
In any case, you can make changes to your local copy.

Well that is to be expected given SPARQL's inside-out evaluation?
But what is the problem with evaluating SELECTs first if the end results are the same? Performance?

yes absolutely, performance is a show stopper because these queries are run thousands of times.

@HolgerKnublauch which filters do you mean exactly? I've now pushed FILTER bound(?minCount)/FILTER bound(?maxCount) down into the SELECTS and I'm still getting the same results:
PREFIX  xsd:  <http://www.w3.org/2001/XMLSchema#>
PREFIX  rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX  rdf:  <http://www.w3.org/1999/02/22-rdf-syntax-ns#>

ASK
WHERE
  {   { SELECT  (count(*) AS ?cardinality)
        WHERE
          { ?this  ?predicate  ?object
            FILTER bound(?minCount)
          }
        HAVING ( ?cardinality < ?minCount )
      }
    UNION
      { { SELECT  (count(*) AS ?cardinality)
          WHERE
            { ?this  ?predicate  ?object
              FILTER bound(?maxCount)
            }
          HAVING ( ?cardinality > ?maxCount )
        }
      }
    UNION
      { ?this  ?predicate  ?object
        FILTER ( isURI(?object) || isBlank(?object) )
        FILTER bound(?valueType)
        FILTER NOT EXISTS { ?object  rdf:type  ?class .
                            ?class (rdfs:subClassOf)* ?valueType
                          }
      }
    UNION
      { ?this  ?predicate  ?object
        FILTER isLiteral(?object)
        FILTER bound(?valueType)
        BIND(datatype(?object) AS ?datatype)
        FILTER ( ! ( ( ?datatype IN (?valueType, rdfs:Literal) ) || ( ( ( ! bound(?datatype) ) || ( ?datatype = rdf:langString ) ) && ( ?valueType = xsd:string ) ) ) )
      }
  }

I guess this query might further be optimized, but I don't think by much.
SPIN function invocation must incur some overhead too?

I don't know what you are trying to solve here but this is likely to have much worse performance than the helper function, as there is no need to iterate through the SPOs if min/maxCount are not bound. And that's what the original solution prevents.

I am trying to refactor the constraint validation using plain SPARQL so that Jena upgrades should not be a problem anymore.
As for performance, the only way to tell is to measure, right? I'll see if I can get that done.

Another issue is that the SPIN model breaks when inference is enabled.

@HolgerKnublauch what is the query for spl:Argument?
I've decoded it to something like this, but would like to double-check:
PREFIX  rdf:  <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
PREFIX  spin: <http://spinrdf.org/spin#>
PREFIX  xsd:  <http://www.w3.org/2001/XMLSchema#>
PREFIX  afn:  <http://jena.apache.org/ARQ/function#>
PREFIX  rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX  spl:  <http://spinrdf.org/spl#>

CONSTRUCT
  {
    _:c0 rdf:type spin:ConstraintViolation .
    _:c0 spin:violationRoot ?this .
    _:c0 spin:violationPath ?predicate .
    _:c0 rdfs:label ?label .
  }
WHERE
  { FILTER isIRI(?this)
      { FILTER ( ( ! bound(?optional) ) || ( ?optional = false ) )
        FILTER NOT EXISTS { ?this  ?predicate  ?value }
        FILTER NOT EXISTS { ?this  rdf:type  ?template
                            FILTER spl:instanceOf(?template, spl:UnionTemplate)
                          }
        BIND(concat("Missing value for argument ", afn:localname(?predicate)) AS ?label)
      }
    UNION
      { FILTER bound(?valueType)
        ?this  ?predicate  ?value
        FILTER ( ( ! spl:instanceOf(?value, ?valueType) ) && ( ( ?valueType != rdfs:Resource ) || isLiteral(?value) ) )
        BIND(concat("Incorrect type of argument ", afn:localname(?predicate), " (expected: ", afn:localname(?valueType), ")") AS ?label)
      }
  }

Looks semantically correct although probably less efficient because depending on execution settings it may push the FILTER bound(?valueType) to after the BGP and thus do unnecessary work. In my version that's
CONSTRUCT {     _:b0 a spin:ConstraintViolation .     _:b0 spin:violationRoot ?this .     _:b0 spin:violationPath ?predicate .     _:b0 rdfs:label ?label . } WHERE {     {         FILTER isIRI(?this) .     } .     {         {             {                 FILTER ((!bound(?optional)) || (?optional = false)) .             } .             FILTER NOT EXISTS {                 ?this ?predicate ?value .             } .             FILTER NOT EXISTS {                 ?this a ?template .                 FILTER spl:instanceOf(?template, spl:UnionTemplate) .             } .         } .         BIND (CONCAT("Missing value for argument ", afn:localname(?predicate)) AS ?label) .     }     UNION     {         {             {                 FILTER bound(?valueType) .             } .             ?this ?predicate ?value .             FILTER ((!spl:instanceOf(?value, ?valueType)) && ((?valueType != rdfs:Resource) || isLiteral(?value))) .         } .         BIND (CONCAT("Incorrect type of argument ", afn:localname(?predicate), " (expected: ", afn:localname(?valueType), ")") AS ?label) .     } . }

authors: HolgerKnublauch namedgraph

repo: spinrdf/spinrdf


text:
Error Unexpected error could not find a temporary directory when starting container based on splunk/fluentd-hec:1.3.1 image

What happened:
Container based on image splunk/fluentd-hec:1.3.1 and newer versions throws an error when running CMD instruction (bundle exec fluentd -c /fluentd/etc/fluent.conf).
It is working properly in version 1.3.0.
Error message:
2022-11-28 15:45:16 +0000 [info]: init supervisor logger path=nil rotate_age=nil rotate_size=nil
2022-11-28 15:45:17 +0000 [info]: parsing config file is succeeded path="/fluentd/etc/fluent.conf"
2022-11-28 15:45:17 +0000 [info]: gem 'fluentd' version '1.15.3'
2022-11-28 15:45:17 +0000 [info]: gem 'fluent-plugin-concat' version '2.4.0'
2022-11-28 15:45:17 +0000 [info]: gem 'fluent-plugin-jq' version '0.5.1'
2022-11-28 15:45:17 +0000 [info]: gem 'fluent-plugin-kubernetes_metadata_filter' version '3.1.0'
2022-11-28 15:45:17 +0000 [info]: gem 'fluent-plugin-prometheus' version '2.0.2'
2022-11-28 15:45:17 +0000 [info]: gem 'fluent-plugin-record-modifier' version '2.1.0'
2022-11-28 15:45:17 +0000 [info]: gem 'fluent-plugin-splunk-hec' version '1.3.1'
2022-11-28 15:45:17 +0000 [info]: gem 'fluent-plugin-systemd' version '1.0.2'
2022-11-28 15:45:17 +0000 [info]: using configuration file: <ROOT>
</ROOT>
2022-11-28 15:45:17 +0000 [info]: starting fluentd-1.15.3 pid=1 ruby="2.7.6"
2022-11-28 15:45:17 +0000 [info]: spawn command to main:  cmdline=["/usr/bin/ruby", "-r/usr/local/share/gems/gems/bundler-2.3.26/lib/bundler/setup", "-Eascii-8bit:ascii-8bit", "/usr/bin/fluentd", "-c", "/fluentd/etc/fluent.conf", "--under-supervisor"]
2022-11-28 15:45:17 +0000 [info]: init supervisor logger path=nil rotate_age=nil rotate_size=nil
Unexpected error could not find a temporary directory
  /usr/share/ruby/tmpdir.rb:32:in `tmpdir'
  /usr/share/ruby/tmpdir.rb:108:in `tmpdir'
  /usr/share/ruby/tmpdir.rb:115:in `create'
  /usr/share/ruby/tmpdir.rb:83:in `mktmpdir'
  /usr/share/gems/gems/fluentd-1.15.3/lib/fluent/supervisor.rb:47:in `before_run'
  /usr/share/gems/gems/serverengine-2.3.0/lib/serverengine/server.rb:125:in `main'
  /usr/share/gems/gems/serverengine-2.3.0/lib/serverengine/daemon.rb:119:in `main'
  /usr/share/gems/gems/serverengine-2.3.0/lib/serverengine/daemon.rb:68:in `run'
  /usr/share/gems/gems/fluentd-1.15.3/lib/fluent/supervisor.rb:902:in `supervise'
  /usr/share/gems/gems/fluentd-1.15.3/lib/fluent/supervisor.rb:742:in `run_supervisor'
  /usr/share/gems/gems/fluentd-1.15.3/lib/fluent/command/fluentd.rb:350:in `<top (required)>'
  /usr/share/gems/gems/fluentd-1.15.3/bin/fluentd:15:in `require'
  /usr/share/gems/gems/fluentd-1.15.3/bin/fluentd:15:in `<top (required)>'
  /usr/bin/fluentd:23:in `load'
  /usr/bin/fluentd:23:in `<top (required)>'
  /usr/local/share/gems/gems/bundler-2.3.26/lib/bundler/cli/exec.rb:58:in `load'
  /usr/local/share/gems/gems/bundler-2.3.26/lib/bundler/cli/exec.rb:58:in `kernel_load'
  /usr/local/share/gems/gems/bundler-2.3.26/lib/bundler/cli/exec.rb:23:in `run'
  /usr/local/share/gems/gems/bundler-2.3.26/lib/bundler/cli.rb:486:in `exec'
  /usr/local/share/gems/gems/bundler-2.3.26/lib/bundler/vendor/thor/lib/thor/command.rb:27:in `run'
  /usr/local/share/gems/gems/bundler-2.3.26/lib/bundler/vendor/thor/lib/thor/invocation.rb:127:in `invoke_command'
  /usr/local/share/gems/gems/bundler-2.3.26/lib/bundler/vendor/thor/lib/thor.rb:392:in `dispatch'
  /usr/local/share/gems/gems/bundler-2.3.26/lib/bundler/cli.rb:31:in `dispatch'
  /usr/local/share/gems/gems/bundler-2.3.26/lib/bundler/vendor/thor/lib/thor/base.rb:485:in `start'
  /usr/local/share/gems/gems/bundler-2.3.26/lib/bundler/cli.rb:25:in `start'
  /usr/local/share/gems/gems/bundler-2.3.26/exe/bundle:48:in `block in <top (required)>'
  /usr/local/share/gems/gems/bundler-2.3.26/lib/bundler/friendly_errors.rb:120:in `with_friendly_errors'
  /usr/local/share/gems/gems/bundler-2.3.26/exe/bundle:36:in `<top (required)>'
  /usr/local/bin/bundle:23:in `load'
  /usr/local/bin/bundle:23:in `<main>'

What you expected to happen:
Start container without an error.
How to reproduce it (as minimally and precisely as possible):
In current directory create empty fluent.conf file and run this command:
docker run -v "$(pwd)"/fluent.conf:/fluentd/etc/fluent.conf splunk/fluentd-hec:1.3.1
or
docker run -v "$(pwd)"/fluent.conf:/fluentd/etc/fluent.conf splunk/fluentd-hec:latest
Anything else we need to know?:
It's probably caused of missing sticky bit set on /tmp/ directory - check these Stackoverflow answers ->
https://stackoverflow.com/a/31182540 and https://stackoverflow.com/a/40619833.
Comparision - 1.3.0 vs 1.3.1
Version 1.3.1
➜  ~ docker run -d -v "$(pwd)"/fluent.conf:/fluentd/etc/fluent.conf splunk/fluentd-hec:1.3.1 sleep infinity
d2b7f34908a1d19547380ad761e7765ce5f530003a50504ef80a6b8be45816e6
➜  ~ docker exec -it d2 ls -ld /tmp
drwxrwxrwx 1 root root 4096 Nov 23 12:37 /tmp

Version 1.3.0
➜  ~ docker run -d -v "$(pwd)"/fluent.conf:/fluentd/etc/fluent.conf splunk/fluentd-hec:1.3.0 sleep infinity
4522591f89673455c289513c8ff8233d75bba8c9c303bdee04c22b03cd305d4f
➜  ~ docker exec -it 45 ls -ld /tmp
drwxrwxrwt 1 root root 4096 Aug 16 12:12 /tmp

Fix - add sticky bit:
➜  docker run -d -v "$(pwd)"/fluent.conf:/fluentd/etc/fluent.conf splunk/fluentd-hec:1.3.1 sleep infinity
3c8f549394599d4dcd0049ee93818410ce93f0e0e127f2ff5182770e91dd5b8b
➜  docker exec -it 3c bundle exec fluentd -c /fluentd/etc/fluent.conf
...
Unexpected error could not find a temporary directory
  /usr/share/ruby/tmpdir.rb:32:in `tmpdir'
...
➜  docker exec -it -u root 3c chmod +t /tmp
➜  docker exec -it 3c bundle exec fluentd -c /fluentd/etc/fluent.conf
...
2022-11-28 16:19:06 +0000 [info]: #0 starting fluentd worker pid=33 ppid=23 worker=0
2022-11-28 16:19:06 +0000 [info]: #0 fluentd worker is now running worker=0

Environment:

Kubernetes version (use kubectl version): N/A
Ruby version (use ruby --version): N/A
OS (e.g: cat /etc/os-release): N/A
Splunk version: N/A
Others:

@miko083, thanks for reporting the bug. I have updated the 1.3.1 image with sticky bit on tmp directory.

repo: splunk/fluent-plugin-splunk-hec


text:
ProxyShell & PetitPotam

New Analytic Story

ProxyShell
PetitPotam NTLM Relay on Active Directory Certificate Services

New Analytics

Exchange PowerShell Module Usage (Experimental)
Exchange PowerShell Abuse via SSRF (Experimental)
PetitPotam Network Share Access Request
Windows Kerberos Auth Ticket Request

This PR was created by Automated Detection Testing Service :robot:
Tested detections:
PetitPotam Suspicious Kerberos TGT Request :white_check_mark:

diskUsage: 204800
runDuration: 1.462s
scanCount: 1

This PR was created by Automated Detection Testing Service :robot:
Tested detections:
Windows Desired Access Request :white_check_mark:

diskUsage: 200704
runDuration: 1.0050000000000001s
scanCount: 1


text:
How to use a splunk URL instead of protocol/host/port

I've a splunk instance behind an application gateway that is exposed with a url like this https://mydomain.com/splunkhec/
How can I use this url instead of the protocol/host/port fields in the splunk-connect values configuration file?
global:
  logLevel: info
  splunk:
    hec:
      # host is required and should be provided by user
      host:
      # port to HEC, optional, default 8088
      port:
      # token is required and should be provided by user
      token:
      # protocol has two options: "http" and "https", default is "https"
      # For self signed certficate leave this field blank
      protocol:

From your example. Set the host to "mydomain.com/splunkhec", port to your HEC port, protocol to "https".

@chaitanyaphalak it does not work, the resulting url passed to the logging pods will be  https://mydomain.com/splunkhec/:port

just found someone had same question but it was not answered https://github.com/splunk/splunk-connect-for-kubernetes/issues/596

Now you can use fullUrl instead of protocol/host/port

authors: chaitanyaphalak dzlab harshit-splunk

repo: splunk/splunk-connect-for-kubernetes


text:
subscription button multiple items

Hi,
I'm Using Django-Paypal 0.3.3 and got IPN working. But I have a question and can't find the answer anywhere else.
I'm trying to create a subscription button with a choice of multiple items from a dropdown in the button, i.e. basic, pro etc with different prices. I created a similar button in the Paypal Sandbox but couldn't replicate this using the "paypal_dict".  Is this supported in Django-Paypal?
Now I tried to create a workaround creating separate buttons for the different plans but the render funtion "{{form.render}}" in the html template seems to only render a single button.
Hope you guys can advice or share a solution.
Thank you all
Q.

You'll need to post details of what you created with the PayPal Sandbox - I don't know about its features.

Here is the HTML Code used for this button:
<form action="https://www.sandbox.paypal.com/cgi-bin/webscr" method="post" target="_top">
<input type="hidden" name="cmd" value="_s-xclick">
<input type="hidden" name="hosted_button_id" value="xxxxxx">

<input type="hidden" name="on0" value="Subscription category">Subscription category

<select name="os0">
	<option value="Basic">Basic : €147,00 EUR - monthly</option>
	<option value="Pro">Pro : €247,00 EUR - monthly</option>
	<option value="Unlimited">Unlimited : €467,00 EUR - monthly</option>
</select>

<input type="hidden" name="currency_code" value="EUR">
<input type="image" src="https://www.sandbox.paypal.com/nl_NL/NL/i/btn/btn_subscribeCC_LG.gif" border="0" name="submit" alt="PayPal, de veilige en complete manier van online betalen.">

</form>

And in views.py using the paypal_dic I try to replicate it using these variables to somehow create a dropdown
paypal_dict = {
"cmd": "_xclick-subscriptions",
"business": "myemail",
"option_index": "1",
"on0": "Subscription category",
"os0": "Basic",
"os1": "something",
"option_select0": "option1",
"option_amount0": "147",
"option_select1": "option2",
"option_amount1": "246",
"currency_code": "EUR",
"p3": "1",
"t3": "M",
"src": "1",
"sra": "1",
"no_note": "1",
"custom": "0",
"item_name": "Basic subscription",
"notify_url": "http://efc9155567.ngrok.io/accounts/register/account_activated/",
"return_url": "http://efc9155567.ngrok.io/",
"cancel_return": "http//www.example.com/cancel-location/",

Yes, we don't support this, and there wouldn't be an easy way to build in support for all the possibilities.
There are a few approaches you could take:

Just copy and paste the generated HTML

If this is not sufficient e.g. you need the notify_url and other parameters, then merge together the two forms - the one generated by django-paypal and the one from the PayPal Sandbox site.

For both these cases, you won't be using django-paypal to finally generate the form, you will just have a block of HTML in your template. This has the disadvantage that things like the form action URL won't adjust automatically for test mode.

Do not attempt to pass into paypal_dict the fields that need to be a drop down box. Instead of using {{ form.render }}, use {{ form.as_p }}. This will render out only the hidden fields. To this, you will then need to manually add the <form> tag, and the other bits you need - the <select> drop down for example.

Subclass PayPalPaymentsForm and add a field for the dropdown, using the normal Django forms API - https://docs.djangoproject.com/en/1.10/topics/forms/ . In this way you can add a visible field to the form for the <select> (all the predefined fields on this form are hidden). This is the neatest solution, but perhaps requires you to understand more. I've used it successfully in the past - e.g. see https://bitbucket.org/spookylukey/cciw-website/src/7c777391cac2320b798997a652372edad3b5fe6a/cciw/bookings/views.py?at=default&fileviewer=file-view-default#views.py-803 where I have a form that allows people to put in the amount that they want to pay in some cases. In your cases you would be using a choices rather than letting people enter what they wanted to, and probably for a different field. But the principle is the same.

Yes, we don't support this, and there wouldn't be an easy way to build in support for all the possibilities.
There are a few approaches you could take:

Just copy and paste the generated HTML

If this is not sufficient e.g. you need the notify_url and other parameters, then merge together the two forms - the one generated by django-paypal and the one from the PayPal Sandbox site.

For both these cases, you won't be using django-paypal to finally generate the form, you will just have a block of HTML in your template. This has the disadvantage that things like the form action URL won't adjust automatically for test mode.

Do not attempt to pass into paypal_dict the fields that need to be a drop down box. Instead of using {{ form.render }}, use {{ form.as_p }}. This will render out only the hidden fields. To this, you will then need to manually add the <form> tag, and the other bits you need - the <select> drop down for example.

Subclass PayPalPaymentsForm and add a field for the dropdown, using the normal Django forms API - https://docs.djangoproject.com/en/1.10/topics/forms/ . In this way you can add a visible field to the form for the <select> (all the predefined fields on this form are hidden). This is the neatest solution, but perhaps requires you to understand more. I've used it successfully in the past - e.g. see https://bitbucket.org/spookylukey/cciw-website/src/7c777391cac2320b798997a652372edad3b5fe6a/cciw/bookings/views.py?at=default&fileviewer=file-view-default#views.py-803 where I have a form that allows people to put in the amount that they want to pay in some cases. In your cases you would be using a choices rather than letting people enter what they wanted to, and probably for a different field. But the principle is the same.

Thanks for the information provided.
If any others are interested, I've chosen to use the html button as suggested above instead of using the "paypal_dict". In the sandbox I generated the HTML button and added a "custom" hidden field which takes variables. The notify url for the IPN can also be set in the Sandbox, just like the return and cancel URL.

repo: spookylukey/django-paypal


text:
Specify class_name for associations

Hi, how to specify class_name: "MyCustomClass" for associations?
For example:
has_many_documents :my_document, class_name: 'MyCustomDocument'
I think this feature is not provided.
Thanks.

I accidentally overridden the has_many_documents  in application_controller.rb.
The has_many_documents  accept class_name params and it work well!


text:
Grab song from youtube if can't be found on music youtube

Requested Feature
Sometimes it seems songs can't be found using music.youtube.com can you make it if it can't be found using music.youtube.com the song is downloaded from youtube instead.
Possible implementation
No response

That's already possible just add --audio youtube-music youtube to command line.

That's already possible just add --audio youtube-music youtube to command line.

So do spotdl download --audio youtube-music youtube ?

Yep, this way if song isn't on youtube music spotDL will try searching for it on youtube. You can change the order or try other providers. Check spotdl --help for more info.

repo: spotDL/spotify-downloader


text:
Pip fails to install latest versions

System OS
Termux (Android)
Python Version
3.11 (CPython)
Install Source
pip / PyPi
Install version / commit hash
v4.2.2
Expected Behavior vs Actual Behavior
Expected: pip should install spotdl v4.2.2
Actual: pip raises a subprocess-exited-with-error and exits
Steps to reproduce - Ensure to include actual links!

Install Termux
Install pip and python in Termux
run pip install spotdl

Traceback
pip install spotdl                   Collecting spotdl
  Using cached spotdl-4.2.2-py3-none-any.whl.metadata (8.2 kB)
Requirement already satisfied: beautifulsoup4<5.0.0,>=4.12.2 in /data/data/com.termux/files/usr/lib/python3.11/site-packages (from spotdl) (4.12.2)
Collecting fastapi<0.104.0,>=0.103.0 (from spotdl)
  Using cached fastapi-0.103.2-py3-none-any.whl.metadata (24 kB)
Collecting mutagen<2.0.0,>=1.47.0 (from spotdl)           Using cached mutagen-1.47.0-py3-none-any.whl.metadata (1.7 kB)                                                Collecting platformdirs<5.0.0,>=4.0.0 (from spotdl)       Using cached platformdirs-4.0.0-py3-none-any.whl.metadata (11 kB)                                             Collecting pydantic<3.0.0,>=2.5.1 (from spotdl)           Using cached pydantic-2.5.2-py3-none-any.whl.metadata (65 kB)
Requirement already satisfied: pykakasi<3.0.0,>=2.2.1 in /data/data/com.termux/files/usr/lib/python3.11/site-packages (from spotdl) (2.2.1)                             Requirement already satisfied: python-slugify<9.0.0,>=8.0.1 in /data/data/com.termux/files/usr/lib/python3.11/site-packages (from python-slugify[unidecode]<9.0.0,>=8.0.1->spotdl) (8.0.1)
Collecting pytube<16.0.0,>=15.0.0 (from spotdl)
  Using cached pytube-15.0.0-py3-none-any.whl (57 kB)   Requirement already satisfied: rapidfuzz==2.15.1 in /data/data/com.termux/files/usr/lib/python3.11/site-packages (from spotdl) (2.15.1)
Collecting requests<3.0.0,>=2.31.0 (from spotdl)          Using cached requests-2.31.0-py3-none-any.whl.metadata (4.6 kB)                                               Collecting rich<14.0.0,>=13.7.0 (from spotdl)             Using cached rich-13.7.0-py3-none-any.whl.metadata (18 kB)
Collecting soundcloud-v2<2.0.0,>=1.3.1 (from spotdl)      Using cached soundcloud_v2-1.3.1-py3-none-any.whl (13 kB)                                                     Requirement already satisfied: spotipy<3.0.0,>=2.23.0 in /data/data/com.termux/files/usr/lib/python3.11/site-packages (from spotdl) (2.23.0)                            Collecting syncedlyrics<0.6.0,>=0.5.0 (from spotdl)
  Using cached syncedlyrics-0.5.0-py3-none-any.whl (12 kB)
Collecting uvicorn<0.24.0,>=0.23.2 (from spotdl)          Using cached uvicorn-0.23.2-py3-none-any.whl.metadata (6.2 kB)                                                Collecting yt-dlp<2024.0.0,>=2023.11.16 (from spotdl)     Using cached yt_dlp-2023.11.16-py2.py3-none-any.whl.metadata (160 kB)
Collecting ytmusicapi<2.0.0,>=1.3.2 (from spotdl)         Using cached ytmusicapi-1.3.2-py3-none-any.whl.metadata (5.5 kB)
Requirement already satisfied: soupsieve>1.2 in /data/data/com.termux/files/usr/lib/python3.11/site-packages (from beautifulsoup4<5.0.0,>=4.12.2->spotdl) (2.4)         Collecting anyio<4.0.0,>=3.7.1 (from fastapi<0.104.0,>=0.103.0->spotdl)
  Using cached anyio-3.7.1-py3-none-any.whl.metadata (4.7 kB)                                                   Collecting starlette<0.28.0,>=0.27.0 (from fastapi<0.104.0,>=0.103.0->spotdl)                                     Using cached starlette-0.27.0-py3-none-any.whl.metadata (5.8 kB)                                              Requirement already satisfied: typing-extensions>=4.5.0 in /data/data/com.termux/files/usr/lib/python3.11/site-packages (from fastapi<0.104.0,>=0.103.0->spotdl) (4.5.0)Collecting annotated-types>=0.4.0 (from pydantic<3.0.0,>=2.5.1->spotdl)                                           Using cached annotated_types-0.6.0-py3-none-any.whl.metadata (12 kB)
Collecting pydantic-core==2.14.5 (from pydantic<3.0.0,>=2.5.1->spotdl)                                            Using cached pydantic_core-2.14.5.tar.gz (360 kB)       Installing build dependencies ... error
  error: subprocess-exited-with-error
                                                          × pip subprocess to install build dependencies did not run successfully.
  │ exit code: 1                                          ╰─> [60 lines of output]                                    Collecting maturin<2,>=1                                  Using cached maturin-1.3.2.tar.gz (176 kB)              Installing build dependencies: started                  Installing build dependencies: finished with status 'done'                                                      Getting requirements to build wheel: started            Getting requirements to build wheel: finished with status 'done'
        Preparing metadata (pyproject.toml): started            Preparing metadata (pyproject.toml): finished with status 'done'                                              Collecting typing-extensions!=4.7.0,>=4.6.0               Using cached typing_extensions-4.8.0-py3-none-any.whl.metadata (3.0 kB)                                       Using cached typing_extensions-4.8.0-py3-none-any.whl (31 kB)                                                   Building wheels for collected packages: maturin           Building wheel for maturin (pyproject.toml): started
        Building wheel for maturin (pyproject.toml): finished with status 'error'
        error: subprocess-exited-with-error                                                                             × Building wheel for maturin (pyproject.toml) did not run successfully.
        │ exit code: 1                                          ╰─> [35 lines of output]                                    /data/data/com.termux/files/usr/tmp/pip-build-env-l8zrluz0/overlay/lib/python3.11/site-packages/setuptools/config/_apply_pyprojecttoml.py:82: SetuptoolsWarning: `install_requires` overwritten in `pyproject.toml` (dependencies)
              corresp(dist, value, root_dir)
            running bdist_wheel
            running build                                           running build_py
            creating build
            creating build/lib.linux-aarch64-cpython-311            creating build/lib.linux-aarch64-cpython-311/maturin                                                            copying maturin/__init__.py -> build/lib.linux-aarch64-cpython-311/maturin
            copying maturin/__main__.py -> build/lib.linux-aarch64-cpython-311/maturin                                      copying maturin/import_hook.py -> build/lib.linux-aarch64-cpython-311/maturin                                   running egg_info
            creating maturin.egg-info                               writing maturin.egg-info/PKG-INFO                       writing dependency_links to maturin.egg-info/dependency_links.txt
            writing requirements to maturin.egg-info/requires.txt                                                           writing top-level names to maturin.egg-info/top_level.txt
            writing manifest file 'maturin.egg-info/SOURCES.txt'                                                            reading manifest file 'maturin.egg-info/SOURCES.txt'
            reading manifest template 'MANIFEST.in'
            warning: no files found matching '*.json' under directory 'src/python_interpreter'                              writing manifest file 'maturin.egg-info/SOURCES.txt'
            running build_ext
            running build_rust                                      error: can't find Rust compiler
            If you are using an outdated pip version, it is possible a prebuilt wheel is available for this package but pip is not able to install from it. Installing from the wheel would avoid the need for a Rust compiler.
                                                                    To update pip, run:
                pip install --upgrade pip
                                                                    and then retry package installation.
                                                                    If you did intend to build this package from source, try installing a Rust compiler from your system package manager and ensure it is on the PATH during installation. Alternatively, rustup (available at https://rustup.rs) is the recommended way to download and update the Rust compiler toolchain.                                        [end of output]
                                                                note: This error originates from a subprocess, and is likely not a problem with pip.
        ERROR: Failed building wheel for maturin              Failed to build maturin                                 ERROR: Could not build wheels for maturin, which is required to install pyproject.toml-based projects           [end of output]
                                                          note: This error originates from a subprocess, and is likely not a problem with pip.                          error: subprocess-exited-with-error
                                                        × pip subprocess to install build dependencies did not run successfully.                                        │ exit code: 1
╰─> See above for output.
note: This error originates from a subprocess, and is likely not a problem with pip.

Other details
This issue also occurs for versions 4.2.0 and 4.2.1, however not with earlier versions.
Note that the Termux installation script also fails with the same error.

U can just install this package first by typing
pkg install rust

are you using the latest version of termux?
have you updated package repos? pkg update -y

have you tried this
If you are using an outdated pip version, it is possible a prebuilt wheel is available for this package but pip is not able to install from it. Installing from the wheel would avoid the need for a Rust compiler.
                                                                    To update pip, run:
                pip install --upgrade pip

pkg upgrade
pkg install rust

ERROR: Command errored out with exit status 1:
command: /usr/bin/python -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-HCyR4b/titlecase/setup.py'"'"'; file='"'"'/tmp/pip-install-HCyR4b/titlecase/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(file);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' egg_info --egg-base /tmp/pip-pip-egg-info-ry1FR4
cwd: /tmp/pip-install-HCyR4b/titlecase/
Complete output (9 lines):
Traceback (most recent call last):
File "", line 1, in
File "/tmp/pip-install-HCyR4b/titlecase/setup.py", line 21, in
version=read_version('titlecase/init.py'),
File "/tmp/pip-install-HCyR4b/titlecase/setup.py", line 13, in read_version
for line in read_file(rel_path).splitlines():
File "/tmp/pip-install-HCyR4b/titlecase/setup.py", line 9, in read_file
with open(abs_path, encoding='UTF-8') as f:
TypeError: 'encoding' is an invalid keyword argument for this function
----------------------------------------
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.


text:
build on Java 11

We should start building Helios on Java 11 in CI.
This seems like it will be somewhat of a headache, or at least not possible today. We use the "machine"-based builds in CircleCI which at time of writing run on Ubuntu 14.04 which only has Java 8 available.
https://circleci.com/docs/2.0/executor-types/#using-machine mentions it is possible to specify the image of the "machine" to be used, but it looks to me like all of them have the same OS/distribution.
See also https://discuss.circleci.com/t/image-with-oracles-java-10/23220
I don't have a solution in mind yet but am opening this to track it at least.

will need to bump docker-client to 8.14.0 to make it Java 9+ compatible

WIP here https://github.com/spotify/helios/pull/1242

authors: davidxia mattnworb

repo: spotify/helios


text:
Don't print nested stack traces for run() failures

In python3, stack traces seem to report if the raised exception happened
during another exception handling. It will then say something like
"exception happned during handling of above exception". This is nice,
but just cluttery in the case of our tracking_url_callback hack.

Does this look sane to you @erikbern?

repo: spotify/luigi


text:
Fix incorrect test with in_zone_file chain

This is work in progress pull request.(Done 2015-01-31 22:25:55 UTC)
I found in_zone_file usecase has a bug, and in_zone_file chain cannot evaluate zone file correctly. Now, if we use in_zone_file, have_dns passes following example(doubt.example.com should be failed, but does not).
I'm doing fixing this bug.
zone_file(example.zone)
$TTL 86400

@ IN SOA  ns.example.com.  root.example.com. (
          2014122413  ; Serial
          3600        ; Refresh
          900         ; Retry
          604800      ; Expire
          900         ; Minimum
          )
          IN NS        ns
          IN MX   40   mail
          IN A         192.0.2.4
www       IN A         192.0.2.4
www       IN AAAA      2001:DB8:6C::430

spec
    context 'with zone file' do
      it 'can evalutate records in zone file with origin' do
        file = 'spec/rspec-dns/example.zone'
        origin =  'example.com.'

        expect('www.example.com').to have_dns.with_type('A')
          .and_address('192.0.2.4')
          .in_zone_file(file, origin)
        expect('doubt.example.com').to have_dns.with_type('A')
          .and_address('192.0.2.4')
          .in_zone_file(file, origin)
      end
    end

@vzctl,
I am sorry for this bug. I have done the fixation, please check it.

Looks good! By the way, your pull requests are awesome and I really appreciate that you cover all the bugs with tests, great job!

authors: otahi vzctl

repo: spotify/rspec-dns


text:
Error: Not Allowed

Hi guys,
I am trying to set up the exporter but I couldn't. Try with the username and password that I set still not allow.
My pgbouncer auth type is trust.

any help please, much appreciated

hi @kcteh
I had the same problem and the problem was that the user you use in exporter is not an admin one in pgbouncer config /pgbouncer/pgbouncer.config
[pgbouncer]
admin_users=...

authors: kcteh lwsanty

repo: spreaker/prometheus-pgbouncer-exporter


text:
Automatically create invoice for completed orders

How can I call the document (invoice) constructor from within the checkout process or how can I call print_invoice without having to access the backend?
I would like to have the invoice created and stored as .pdf automatically as soon as the checkout is completed without having to create the invoice for every order manually.
Thank you!

As mentioned in the readme you have to enable the store pdf feature. Put this into an initializer:
Spree::PrintInvoice::Config.set(store_pdf: true)
Spree::PrintInvoice::Config.set(storage_path: 'pdfs/orders') # Default: tmp/order_prints

The pdf is then automatically created when the order reaches the complete state.
Hope this helps

I have of course enabled pdf storing in the settings according to the readme, but for me the pdfs are not generated automatically. The pdfs are generated only when clicking on "Print Invoice" in the admin tool.
Automatically creating when reaching the complete state would be exactly what I need...
Thank you once more!

/c @mamhoff

Hi @SimPru !
You can create an invoice by calling
@order.invoice.pdf # for very recent versions of `spree_print_invoice`

or
@order.pdf_file # for older versions of spree_print_invoice

When the order state changes to complete, spree_print_invoice creates an database entry for the PDF, but does not render the file right away. If you want to accomplish that, put the following into an order decorator app/models/spree/order_decorator.rb:
Spree::Order.state_machine.after_transition to: :complete, do: :pdf_file

HTH
Martin

Hi Martin,
thank you for your help (that solved it) and thanks to all of you for that gem, saved me a lot of time.
Simon

authors: SimPru mamhoff tvdeyen


text:
sentinel support custom block response by sentinelClientHttpResponse

sentinel support custom block response by sentinelClientHttpResponse

LGTM


text:
Failing test in CI

RibbonFallbackTest.testFallBackGreetingEndpoint()
https://jenkins.spring.io/blue/organizations/jenkins/spring-cloud-kubernetes-master-ci/detail/spring-cloud-kubernetes-master-ci/1603/pipeline

I don't have access

This test is failing as the service.occurence value must be changed for machine which are faster than CircleCi -> https://github.com/cmoulliard/spring-cloud-kubernetes/blob/ba558139e71bd4f4275b9c09911b6020875d97d9/spring-cloud-kubernetes-ribbon/pom.xml#L145

Failed

org.springframework.cloud.kubernetes.ribbon.RibbonFallbackTest.testFallBackGreetingEndpoint

Failing for the past 49 builds (Since Failed#1579 )
Took 3 sec.
Error Message

expected:<[No instances available for testapp]> but was:<[404 Client Error]>
Stacktrace

org.junit.ComparisonFailure: expected:<[No instances available for testapp]> but was:<[404 Client Error]>
	at org.springframework.cloud.kubernetes.ribbon.RibbonFallbackTest.testFallBackGreetingEndpoint(RibbonFallbackTest.java:114)
Standard Output

2017-07-07 16:14:51.941  INFO   --- [           main] .b.t.c.SpringBootTestContextBootstrapper : Neither @ContextConfiguration nor @ContextHierarchy found for test class [org.springframework.cloud.kubernetes.ribbon.RibbonFallbackTest], using SpringBootContextLoader
2017-07-07 16:14:51.949  INFO   --- [           main] o.s.t.c.support.AbstractContextLoader    : Could not detect default resource locations for test class [org.springframework.cloud.kubernetes.ribbon.RibbonFallbackTest]: no resource found for suffixes {-context.xml, Context.groovy}.
2017-07-07 16:14:52.002  INFO   --- [           main] .b.t.c.SpringBootTestContextBootstrapper : Loaded default TestExecutionListener class names from location [META-INF/spring.factories]: [org.springframework.boot.test.mock.mockito.MockitoTestExecutionListener, org.springframework.boot.test.mock.mockito.ResetMocksTestExecutionListener, org.springframework.boot.test.autoconfigure.restdocs.RestDocsTestExecutionListener, org.springframework.boot.test.autoconfigure.web.client.MockRestServiceServerResetTestExecutionListener, org.springframework.boot.test.autoconfigure.web.servlet.MockMvcPrintOnlyOnFailureTestExecutionListener, org.springframework.boot.test.autoconfigure.web.servlet.WebDriverTestExecutionListener, org.springframework.test.context.web.ServletTestExecutionListener, org.springframework.test.context.support.DirtiesContextBeforeModesTestExecutionListener, org.springframework.test.context.support.DependencyInjectionTestExecutionListener, org.springframework.test.context.support.DirtiesContextTestExecutionListener, org.springframework.test.context.transaction.TransactionalTestExecutionListener, org.springframework.test.context.jdbc.SqlScriptsTestExecutionListener]
2017-07-07 16:14:52.015  INFO   --- [           main] .b.t.c.SpringBootTestContextBootstrapper : Could not instantiate TestExecutionListener [org.springframework.test.context.transaction.TransactionalTestExecutionListener]. Specify custom listener classes or make the default listener classes (and their required dependencies) available. Offending class: [org/springframework/transaction/TransactionDefinition]
2017-07-07 16:14:52.016  INFO   --- [           main] .b.t.c.SpringBootTestContextBootstrapper : Could not instantiate TestExecutionListener [org.springframework.test.context.jdbc.SqlScriptsTestExecutionListener]. Specify custom listener classes or make the default listener classes (and their required dependencies) available. Offending class: [org/springframework/transaction/interceptor/TransactionAttribute]
2017-07-07 16:14:52.017  INFO   --- [           main] .b.t.c.SpringBootTestContextBootstrapper : Using TestExecutionListeners: [org.springframework.test.context.web.ServletTestExecutionListener@5ae50ce6, org.springframework.test.context.support.DirtiesContextBeforeModesTestExecutionListener@6f96c77, org.springframework.boot.test.autoconfigure.SpringBootDependencyInjectionTestExecutionListener@be64738, org.springframework.test.context.support.DirtiesContextTestExecutionListener@3ba9ad43, org.springframework.boot.test.mock.mockito.MockitoTestExecutionListener@49d904ec, org.springframework.boot.test.autoconfigure.web.client.MockRestServiceServerResetTestExecutionListener@48e4374, org.springframework.boot.test.mock.mockito.ResetMocksTestExecutionListener@3d680b5a, org.springframework.boot.test.autoconfigure.restdocs.RestDocsTestExecutionListener@4b5d6a01, org.springframework.boot.test.autoconfigure.web.servlet.MockMvcPrintOnlyOnFailureTestExecutionListener@4a22f9e2, org.springframework.boot.test.autoconfigure.web.servlet.WebDriverTestExecutionListener@3c419631]
2017-07-07 16:14:53.823  INFO 16412 --- [           main] s.c.a.AnnotationConfigApplicationContext : Refreshing org.springframework.context.annotation.AnnotationConfigApplicationContext@4a31c2ee: startup date [Fri Jul 07 16:14:53 UTC 2017]; root of context hierarchy
2017-07-07 16:14:54.051  INFO 16412 --- [           main] f.a.AutowiredAnnotationBeanPostProcessor : JSR-330 'javax.inject.Inject' annotation found and supported for autowiring
2017-07-07 16:14:54.092  INFO 16412 --- [           main] trationDelegate$BeanPostProcessorChecker : Bean 'configurationPropertiesRebinderAutoConfiguration' of type [org.springframework.cloud.autoconfigure.ConfigurationPropertiesRebinderAutoConfiguration$$EnhancerBySpringCGLIB$$7f4af7a5] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)

  .   ____          _            __ _ _
 /\\ / ___'_ __ _ _(_)_ __  __ _ \ \ \ \
( ( )\___ | '_ | '_| | '_ \/ _` | \ \ \ \
 \\/  ___)| |_)| | | | | || (_| |  ) ) ) )
  '  |____| .__|_| |_|_| |_\__, | / / / /
 =========|_|==============|___/=/_/_/_/
 :: Spring Boot ::        (v1.5.4.RELEASE)

2017-07-07 16:14:54.408  INFO 16412 --- [           main] o.s.c.k.ribbon.RibbonFallbackTest        : No active profile set, falling back to default profiles: default
2017-07-07 16:14:54.410  INFO 16412 --- [           main] o.s.w.c.s.GenericWebApplicationContext   : Refreshing org.springframework.web.context.support.GenericWebApplicationContext@1e469dfd: startup date [Fri Jul 07 16:14:54 UTC 2017]; parent: org.springframework.context.annotation.AnnotationConfigApplicationContext@4a31c2ee
2017-07-07 16:14:55.164  INFO 16412 --- [           main] o.s.cloud.context.scope.GenericScope     : BeanFactory id=b5e8be5e-ad2d-3620-89bd-8c10b3de1f86
2017-07-07 16:14:55.235  INFO 16412 --- [           main] f.a.AutowiredAnnotationBeanPostProcessor : JSR-330 'javax.inject.Inject' annotation found and supported for autowiring
2017-07-07 16:14:55.322  INFO 16412 --- [           main] trationDelegate$BeanPostProcessorChecker : Bean 'org.springframework.cloud.autoconfigure.ConfigurationPropertiesRebinderAutoConfiguration' of type [org.springframework.cloud.autoconfigure.ConfigurationPropertiesRebinderAutoConfiguration$$EnhancerBySpringCGLIB$$7f4af7a5] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)
2017-07-07 16:14:56.235  INFO 16412 --- [           main] s.w.s.m.m.a.RequestMappingHandlerAdapter : Looking for @ControllerAdvice: org.springframework.web.context.support.GenericWebApplicationContext@1e469dfd: startup date [Fri Jul 07 16:14:54 UTC 2017]; parent: org.springframework.context.annotation.AnnotationConfigApplicationContext@4a31c2ee
2017-07-07 16:14:56.346  INFO 16412 --- [           main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/error],produces=[text/html]}" onto public org.springframework.web.servlet.ModelAndView org.springframework.boot.autoconfigure.web.BasicErrorController.errorHtml(javax.servlet.http.HttpServletRequest,javax.servlet.http.HttpServletResponse)
2017-07-07 16:14:56.347  INFO 16412 --- [           main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/error]}" onto public org.springframework.http.ResponseEntity<java.util.Map<java.lang.String, java.lang.Object>> org.springframework.boot.autoconfigure.web.BasicErrorController.error(javax.servlet.http.HttpServletRequest)
2017-07-07 16:14:56.390  INFO 16412 --- [           main] o.s.w.s.handler.SimpleUrlHandlerMapping  : Mapped URL path [/webjars/**] onto handler of type [class org.springframework.web.servlet.resource.ResourceHttpRequestHandler]
2017-07-07 16:14:56.391  INFO 16412 --- [           main] o.s.w.s.handler.SimpleUrlHandlerMapping  : Mapped URL path [/**] onto handler of type [class org.springframework.web.servlet.resource.ResourceHttpRequestHandler]
2017-07-07 16:14:56.446  INFO 16412 --- [           main] o.s.w.s.handler.SimpleUrlHandlerMapping  : Mapped URL path [/**/favicon.ico] onto handler of type [class org.springframework.web.servlet.resource.ResourceHttpRequestHandler]
2017-07-07 16:14:57.243  WARN 16412 --- [           main] c.n.c.sources.URLConfigurationSource     : No URLs will be polled as dynamic configuration sources.
2017-07-07 16:14:57.244  INFO 16412 --- [           main] c.n.c.sources.URLConfigurationSource     : To enable URLs as dynamic configuration sources, define System property archaius.configurationSource.additionalUrls or make config.properties available on classpath.
2017-07-07 16:14:57.254  WARN 16412 --- [           main] c.n.c.sources.URLConfigurationSource     : No URLs will be polled as dynamic configuration sources.
2017-07-07 16:14:57.255  INFO 16412 --- [           main] c.n.c.sources.URLConfigurationSource     : To enable URLs as dynamic configuration sources, define System property archaius.configurationSource.additionalUrls or make config.properties available on classpath.
2017-07-07 16:14:57.426  INFO 16412 --- [           main] o.s.c.support.DefaultLifecycleProcessor  : Starting beans in phase 0
2017-07-07 16:14:57.448  INFO 16412 --- [           main] o.s.c.k.ribbon.RibbonFallbackTest        : Started RibbonFallbackTest in 4.302 seconds (JVM running for 6.07)
2017-07-07 16:14:57.497  INFO 16412 --- [           main] o.s.c.k.ribbon.RibbonFallbackTest        : >>>>>>>>>> BEGIN PART 1 <<<<<<<<<<<<<
2017-07-07 16:14:57.808  INFO 16412 --- [           main] s.c.a.AnnotationConfigApplicationContext : Refreshing org.springframework.context.annotation.AnnotationConfigApplicationContext@7bbd0006: startup date [Fri Jul 07 16:14:57 UTC 2017]; parent: org.springframework.web.context.support.GenericWebApplicationContext@1e469dfd
2017-07-07 16:14:57.865  INFO 16412 --- [           main] f.a.AutowiredAnnotationBeanPostProcessor : JSR-330 'javax.inject.Inject' annotation found and supported for autowiring
2017-07-07 16:14:58.063  INFO 16412 --- [           main] c.netflix.config.ChainedDynamicProperty  : Flipping property: testapp.ribbon.ActiveConnectionsLimit to use NEXT property: niws.loadbalancer.availabilityFilteringRule.activeConnectionsLimit = 2147483647
2017-07-07 16:14:58.128  INFO 16412 --- [           main] c.netflix.loadbalancer.BaseLoadBalancer  : Client: testapp instantiated a LoadBalancer: DynamicServerListLoadBalancer:{NFLoadBalancer:name=testapp,current list of Servers=[],Load balancer stats=Zone stats: {},Server stats: []}ServerList:null
2017-07-07 16:14:58.143  INFO 16412 --- [           main] c.n.l.DynamicServerListLoadBalancer      : Using serverListUpdater PollingServerListUpdater
2017-07-07 16:14:58.220  INFO 16412 --- [127.0.0.1:49834] okhttp3.mockwebserver.MockWebServer      : MockWebServer[40309] received request: GET /api/v1/namespaces/testns/endpoints/testapp HTTP/1.1 and responded: HTTP/1.1 200 OK
2017-07-07 16:14:58.274  INFO 16412 --- [           main] c.netflix.config.ChainedDynamicProperty  : Flipping property: testapp.ribbon.ActiveConnectionsLimit to use NEXT property: niws.loadbalancer.availabilityFilteringRule.activeConnectionsLimit = 2147483647
2017-07-07 16:14:58.278  INFO 16412 --- [           main] c.n.l.DynamicServerListLoadBalancer      : DynamicServerListLoadBalancer for client testapp initialized: DynamicServerListLoadBalancer:{NFLoadBalancer:name=testapp,current list of Servers=[localhost:39140],Load balancer stats=Zone stats: {unknown=[Zone:unknown;	Instance count:1;	Active connections count: 0;	Circuit breaker tripped count: 0;	Active connections per server: 0.0;]
},Server stats: [[Server:localhost:39140;	Zone:UNKNOWN;	Total Requests:0;	Successive connection failure:0;	Total blackout seconds:0;	Last connection made:Thu Jan 01 00:00:00 UTC 1970;	First connection made: Thu Jan 01 00:00:00 UTC 1970;	Active Connections:0;	total failure count in last (1000) msecs:0;	average resp time:0.0;	90 percentile resp time:0.0;	95 percentile resp time:0.0;	min resp time:0.0;	max resp time:0.0;	stddev resp time:0.0]
]}ServerList:org.springframework.cloud.kubernetes.ribbon.KubernetesServerList@113e6e06
2017-07-07 16:14:58.518  INFO 16412 --- [127.0.0.1:60407] okhttp3.mockwebserver.MockWebServer      : MockWebServer[39140] received request: GET /greeting HTTP/1.1 and responded: HTTP/1.1 200 OK
2017-07-07 16:14:58.531  INFO 16412 --- [           main] o.s.c.k.ribbon.RibbonFallbackTest        : >>>>>>>>>> END PART 1 <<<<<<<<<<<<<
2017-07-07 16:14:58.534  INFO 16412 --- [           main] o.s.c.k.ribbon.RibbonFallbackTest        : >>>>>>>>>> BEGIN PART 2 <<<<<<<<<<<<<
2017-07-07 16:14:59.151  INFO 16412 --- [127.0.0.1:49834] okhttp3.mockwebserver.MockWebServer      : MockWebServer[40309] received request: GET /api/v1/namespaces/testns/endpoints/testapp HTTP/1.1 and responded: HTTP/1.1 200 OK
2017-07-07 16:14:59.152  INFO 16412 --- [erListUpdater-0] c.netflix.config.ChainedDynamicProperty  : Flipping property: testapp.ribbon.ActiveConnectionsLimit to use NEXT property: niws.loadbalancer.availabilityFilteringRule.activeConnectionsLimit = 2147483647
2017-07-07 16:14:59.661  INFO 16412 --- [127.0.0.1:49834] okhttp3.mockwebserver.MockWebServer      : MockWebServer[40309] received request: GET /api/v1/namespaces/testns/endpoints/testapp HTTP/1.1 and responded: HTTP/1.1 200 OK
2017-07-07 16:15:00.164  INFO 16412 --- [127.0.0.1:49834] okhttp3.mockwebserver.MockWebServer      : MockWebServer[40309] received request: GET /api/v1/namespaces/testns/endpoints/testapp HTTP/1.1 and responded: HTTP/1.1 200 OK
2017-07-07 16:15:00.537  INFO 16412 --- [127.0.0.1:60407] okhttp3.mockwebserver.MockWebServer      : MockWebServer[39140] received request: GET /greeting HTTP/1.1 and responded: HTTP/1.1 404 Client Error
Standard Error

Jul 07, 2017 4:14:52 PM okhttp3.mockwebserver.MockWebServer$2 execute
INFO: MockWebServer[40309] starting to accept connections
Jul 07, 2017 4:14:53 PM okhttp3.mockwebserver.MockWebServer$2 execute
INFO: MockWebServer[39140] starting to accept connections

authors: cmoulliard spencergibb


text:
this package doesn't compile

Hi,
I'm having problems using this trigger as dependency in other project
also this same project doesn't seems to build to me.. at least using
those build instruction
https://github.com/spring-cloud-stream-app-starters/trigger/blob/master/spring-cloud-starter-stream-source-trigger/README.adoc
( tested on both master && 1.3.x branch )
$ ./mvnw clean install -PgenerateApps
give this output
[INFO] Compiling 1 source file to /tmp/trigger/spring-cloud-starter-stream-source-trigger/target/test-classes
[INFO] -------------------------------------------------------------
[ERROR] COMPILATION ERROR :
[INFO] -------------------------------------------------------------
[ERROR] /tmp/trigger/spring-cloud-starter-stream-source-trigger/src/test/java/org/springframework/cloud/stream/app/trigger/source/TriggerSourceTests.java:[29,52] package org.springframework.cloud.stream.test.binder does not exist
[ERROR] /tmp/trigger/spring-cloud-starter-stream-source-trigger/src/test/java/org/springframework/cloud/stream/app/trigger/source/TriggerSourceTests.java:[48,19] cannot find symbol
  symbol:   class MessageCollector
  location: class org.springframework.cloud.stream.app.trigger.source.TriggerSourceTests

maybe this is missing ?
<dependency>
			<groupId>org.springframework.cloud</groupId>
			<artifactId>spring-cloud-stream-test-support</artifactId>
			<scope>test</scope>
		</dependency>

@fvigotti Indeed. We're still in the process of upgrading our starters to account for changes and improvements before 2.0 release of spring cloud stream. One of these changes is new test binder (blog and details are coming shortly), hence the issue you see.
In any event, adding the above dependency should take care of the issue.

authors: fvigotti olegz


text:
Customize load balancer/filter to route(forward) single request to all the the active instances of the service

I have API Gateway  with Eureka as service discovery, spring load balancer as LB .
I have 2 instances of a service 'first-service-1' and 'first-service-2' with endpoint say "updateRules"
Whenever there is a call to "updateRules", apigateway has to route the request to all the  active services .In this case to both  'first-service-1' and 'first-service-2'
However, LB will be used for other points as usual . above customization is only for single endpoint.
Is there a way to do this?
I was able to customize GatewayFilter to route the request to one of the manually selected service.
But how to forward the request to multiple  active services?
Any suggestion will be great
Thanks

gateway does not support sending the same request to multiple services.

If you would like us to look at this issue, please provide the requested information. If the information is not provided within the next 7 days this issue will be closed.

Closing due to lack of requested feedback. If you would like us to look at this issue, please provide the requested information and we will re-open the issue.

repo: spring-cloud/spring-cloud-commons


text:
How to modify spring cloud gateway response headers

I am trying  to modify a header of response in a post  filter of  gateway,the filter handle a cors problem  which would filt  websockt service ,the websockt  service is a micro-service which must been decorated with cors configuration，so a websockt request will get a response with multiple header like “Access-Control-Allow-Origin”, to solve this  question，i must modify the response header of the key “Access-Control-Allow-Origin”。However ,when i do this, a error occured：
java.lang.UnsupportedOperationException: null 	at org.springframework.http.ReadOnlyHttpHeaders.set(ReadOnlyHttpHeaders.java:99) ~[spring-web-5.1.6.RELEASE.jar:5.1.6.RELEASE] 	at com.apigw.filter.CORSFilter.lambda$filter$0(CORSFilter.java:84) ~[classes/:na] 	at reactor.core.publisher.MonoRunnable.call(MonoRunnable.java:73) ~[reactor-core-3.2.8.RELEASE.jar:3.2.8.RELEASE]
It seems the response header cannot be modifed in post filter,the following is my code,please tell me a way to solve this problem.
code.txt

Can you provide a complete, minimal, verifiable sample that reproduces the problem? It should be available as a GitHub (or similar) project or attached to this issue as a zip file.

@ryanjbaxter   thanks, the core codes  is a filter of the following ,but  it can't modify header in a post filter,is it a right way writing like this?
@Override     public Mono<Void> filter(ServerWebExchange exchange, GatewayFilterChain chain) {         org.springframework.http.server.reactive.ServerHttpRequest request = exchange.getRequest();         if (CorsUtils.isCorsRequest(request)) {             ServerHttpResponse response = exchange.getResponse();             HttpHeaders headers = response.getHeaders();             String originUrl=request.getHeaders().getOrigin();             if(StringUtils.equals("*",whiteList)){                 headers.set("Access-Control-Allow-Origin",originUrl);             }             else{                 String[] corsUrl=whiteList.split(",");                 boolean corsAllowed=false;                 String originHost=request.getHeaders().getHost().toString();                 for(String str:corsUrl){                     if(StringUtils.equals(str,originHost)){                         corsAllowed=true;                         break;                     }                 }                 if(corsAllowed){                     headers.set("Access-Control-Allow-Origin",originUrl);                 }                 else{                     response.setStatusCode(HttpStatus.FORBIDDEN);                     return Mono.empty();                 }             }             headers.add("Access-Control-Allow-Methods", "PUT,POST,GET,DELETE,OPTIONS");             headers.add("Access-Control-Max-Age", MAX_AGE);             headers.add("Access-Control-Allow-Headers", "x-request-with,Authorization,Content-Type,token,sign,serial,userSerial");             headers.add("Access-Control-Expose-Headers", "token,sign,serial,userSerial");             headers.add("Access-Control-Allow-Credentials", "true");             if (request.getMethod() == HttpMethod.OPTIONS) {                 response.setStatusCode(HttpStatus.OK);                 return Mono.empty();             }         }         return chain.filter(exchange).then(Mono.fromRunnable(() -> {             if(exchange.getRequest().getPath().toString().contains(socketPath)){                 HttpHeaders headers = exchange.getResponse().getHeaders();                 headers.set("Access-Control-Allow-Origin",headers.get("Access-Control-Allow-Origin").get(0));                 headers.set("Access-Control-Allow-Credentials",headers.get("Access-Control-Allow-Credentials").get(0));             }         }));

That is not a complete working sample, it is just some code.
There should be no reason why a filter cannot modify a response header.  We do this already
https://github.com/spring-cloud/spring-cloud-gateway/blob/master/spring-cloud-gateway-core/src/main/java/org/springframework/cloud/gateway/filter/factory/SetResponseHeaderGatewayFilterFactory.java

@ryanjbaxter   it seems a route filter,can i modify a response header in a global post filter

yes

If you would like us to look at this issue, please provide the requested information. If the information is not provided within the next 7 days this issue will be closed.

Closing due to lack of requested feedback. If you would like us to look at this issue, please provide the requested information and we will re-open the issue.

For those that find this when searching for similar issue...
I too was experiencing the UnsupportedOperationException when I added a post filter to an existing global filter which had an order that caused the post filter to action to occur after the response had been sent.

Facing same issue, found any solution?

I suppose your issue may have been different than mine, but when I turned on trace logging I saw that my filter was executing after the response was sent and so I gave the filter a different order value that put it in the right order.  Here is a link to someone asking about ordered filters that may provide more insight: https://github.com/spring-cloud/spring-cloud-gateway/issues/1341

repo: spring-cloud/spring-cloud-gateway


text:
AddRequestParameter double encodes parameter value

Describe the bug
AddRequestParameter encodes the already-encoded value when other parameter is encoded.
There is an remote endpoint which has two request parameters(Say, a and b) which each may need to be url-encoded.
Within my route, I'm intending putting the b parameter's value.
Per, #2717, I configured the b parameter's value as url-encoded.
When sending a with an ascii value, it works.
When sending a with an url-encoded value, the b parameter's value is double-encoded.
# application.yaml

spring:
  cloud:
    gateway:
      routes:
        filters:
          - AddRequestParameter=b, %2F

CLIENT                  GATEWAY
--------------------------------------------------
a=%2F                   a=%2F&b=%2F   OK
a=a                     a=a&b=%252F   NOT OK

            @Override
            public Mono<Void> filter(final ServerWebExchange exchange, final GatewayFilterChain chain) {
                final var request = exchange.getRequest();
                final var uri = request.getURI();
                final var builder = UriComponentsBuilder.fromUri(uri);
                request.getQueryParams().forEach((k, l) -> builder.replaceQueryParam(
                        URLEncoder.encode(k, StandardCharsets.UTF_8),
                        l.stream().map(v -> URLEncoder.encode(v, StandardCharsets.UTF_8)).toList()
                ));
                builder.queryParam(
                        URLEncoder.encode(config.getName(), StandardCharsets.UTF_8),
                        URLEncoder.encode(config.getValue(), StandardCharsets.UTF_8)
                );
                final var newUri = builder.build(true).toUri();
                final var newRequest = exchange.getRequest().mutate().uri(newUri).build();
                return chain.filter(exchange.mutate().request(newRequest).build());
            }


text:
Console log is flooded by strange message

I have been running an application using zuul for a week, and today is the first time that console log is flooded by this message:
INFO [zuul-edge-service,de4097179fd9c9ed,de4097179fd9c9ed,false] 1581 --- [pool-6-thread-1] s.m.s.d.i.HystrixLogCollectorServiceImpl : Command Metrics count empty: 0

and it is kept to be generated continuously. This might cause a degraded application, has anyone sees this message before?
Thank you in advance.

Where is HystrixLogCollectorServiceImpl from?

Well, I have been searching to know that, but I still can't recognize it as well. I can't recognize where it comes from, I don't use hystrix even in my project!

Please reopen if you find it and think it is a problem related to this repo.

repo: spring-cloud/spring-cloud-netflix


text:
Finchley-Snapshot Netflix-Archaius dependency: commons-configuration is runtime

I have recently updated from SpringBoot 1.5.10 to 2.0.1 and Spring Cloud Finchley (2.0.0.BUILD-20180426.110507-1967).
During maven compile I get following error:

COMPILATION ERROR :
cannot access org.apache.commons.configuration.AbstractConfiguration
class file for org.apache.commons.configuration.AbstractConfiguration not found

I'm using the Hystrix ConfigurationManager Class to configure Hystrix at SpringBoot startup.

ConfigurationManager.getConfigInstance().setProperty(
				"hystrix.command.default.execution.isolation.thread.timeoutInMilliseconds",
				config.getHystrix().getTimeoutInMilliseconds());

The problem is the scope for commons-configuration is "runtime", but it should "compile"
Maybe this happend with this commit:
https://github.com/spring-cloud/spring-cloud-netflix/commit/73fbec166ddf591cdfa8aebce59d6279f12cad76#diff-c70ec716b8fb58d81605b2470bbc354e
Maybe earlier, but with SpringBoot 1.5.10 and Spring Cloud Edgware SR3 it was working.

Closed via 2e12d9b473da10351c298a991ddb888ec977152f
@ramato-procon can you give snapshots another try shortly?

@spencergibb Working now. Thank you!

authors: ramato-procon spencergibb


text:
refactor load balance client so that users can add their custom implementation

Is your feature request related to a problem? Please describe.
My application needs to add a custom Client like FeignBlockingLoadBalancerClient, e.g.
public class CustomFeignBlockingLoadBalancerClient implements Client {
  ...
}

CustomFeignBlockingLoadBalancerClient  will add some extensions to FeignBlockingLoadBalancerClient, like tracing.
This works pretty well when using load-balanced clients. But when mixed with load-balanced and non-load-balanced clients, FeignClientFactoryBean hard coded to work with FeignBlockingLoadBalancerClient to get the delegate
		if (client != null) {
			if (client instanceof FeignBlockingLoadBalancerClient) {
				// not load balancing because we have a url,
				// but Spring Cloud LoadBalancer is on the classpath, so unwrap
				client = ((FeignBlockingLoadBalancerClient) client).getDelegate();
			}
			if (client instanceof RetryableFeignBlockingLoadBalancerClient) {
				// not load balancing because we have a url,
				// but Spring Cloud LoadBalancer is on the classpath, so unwrap
				client = ((RetryableFeignBlockingLoadBalancerClient) client).getDelegate();
			}
			builder.client(client);
		}

see https://github.com/spring-cloud/spring-cloud-openfeign/pull/776
Describe the solution you'd like
see https://github.com/spring-cloud/spring-cloud-openfeign/pull/776
Describe alternatives you've considered
see https://github.com/spring-cloud/spring-cloud-openfeign/pull/776
Additional context
NA
This issue is created for future enhancement to loadbalancer client customization.

Hello, @liubao68 - we actually provide tracing solutions. Have you checked that out? In any case, I think it'd be ok to allow for custom FeignLoadBalancerClient solutions. This is not going to be a team priority, but feel free to submit a PR similar to the one you've created before, but against the main branch instead. Please make sure to add tests.

repo: spring-cloud/spring-cloud-openfeign


text:
DLQs do not work with headerMode: raw in spring-cloud-stream-binder-kafka v1.3.2 as KafkaMessageChannelBinder.getErrorMessageHandler always uses EmbeddedHeaderUtils when it encounters a Throwable payload.

DLQs throw when headerMode: raw in spring-cloud-stream-binder-kafka v1.3.2 as KafkaMessageChannelBinder.getErrorMessageHandler always uses EmbeddedHeaderUtils when it encounters a Throwable payload.
Also it seems to me that when the error message payload is not a Throwable the meta-data about the failed record and any of the original headers should be placed in the DLQ message header.
I believe this would require dependency updates.
		<kafka.version>0.11.0.1</kafka.version>
		<spring-kafka.version>1.3.3.RELEASE</spring-kafka.version>
		<spring-integration-kafka.version>2.3.0.RELEASE</spring-integration-kafka.version>

However KafkaBinderJaasInitializerListener uses JaasUtils.LOGIN_CONTEXT_CLIENT which was removed in Kafka 0.11.
So current usage of KafkaBinderJaasInitializerListener may break with newer Kafka clients.
I am not familiar enough with this to fix it and will submit my PR with do not merge.
Additional changes:

Removal of needless byte[]-> ByteBuffer->byte[] actions:
byte[] payload = Utils.toArray(ByteBuffer.wrap((byte[]) record.value()))
Additional meta-data should be added to the DLQ message headers:

	public static final String X_EXCEPTION_FQCN = "x-exception-fqcn";
	public static final String X_ORIGINAL_OFFSET = "x-original-offset";
	public static final String X_ORIGINAL_PARTITION = "x-original-partition";
	public static final String X_ORIGINAL_TIMESTAMP = "x-original-timestamp";
	public static final String X_ORIGINAL_TIMESTAMP_TYPE = "x-original-timestamp-type";

There is a kafka11 artifact (0.11 branch) that supports the 0.11 kafka-clients.
There are instructions at the bottom of the project page for using it instead of the 0.10 binder.

OK I will close then