text:
Link urls being re-used

I know this package is deprecated now so I will try and move to the new package to see if it fixes this but we have a strange issue where we have a simple text of links and the 3rd url is re-used in the 6th link. The strange thing is it only does it in gatsby production/build mode and not dev. We're on the latest 3.0.0 version.
Thought I would report it anyway in case someone has seen this before. In the screenshot below for example the url for the 3rd link "Help Desk" is showing up re-used in the final 6th link "Spring Show Gallery" in prod/build only. I've tried debugging the data and it looks correct.

Turns out I had invalid nesting with a div inside an a in my marks. Changing it to an inline element fixed it.

repo: sanity-io/block-content-to-react


text:
Preview Subscription Connection Interruption

Seeing this error in the console which is preventing the client side preview mode:
The connection to https://6u24pg6u.api.sanity.io/v1/data/listen/production?query=*&effectFormat=mendoza was interrupted while the page was loading.

I'm currently forcing preview to be true (not sure how relevant this variable is when using the client side preview feature).
import ErrorPage from 'next/error'
import { useRouter } from 'next/router'
import { groq } from 'next-sanity'
import {
  getClient,
  usePreviewSubscription,
  urlFor,
  PortableText,
} from '../../../lib/sanity'

const postQuery = groq`
  *[_type == "post" && _id == $postId][0] {
    _id,
    title,
    body,
    mainImage,
    categories[]->{
      _id,
      title
    },
    "slug": slug.current
  }
`

export default function Post({ data, preview }) {
  const router = useRouter()
  if (!router.isFallback && !data.post?.slug) {
    return <ErrorPage statusCode={404} />
  }

  console.log(data)

  const { data: { post } } = usePreviewSubscription(postQuery, {
    params: { postId: data?.post?._id },
    initialData: data,
    enabled: true,
  })

  console.log(post)

  const { title, mainImage, body } = post
  return (

{title}

      <PortableText
        blocks={body}
        serializers={{
          types: {
            code: (props) => (

                {props.node.code}

            ),
          },
        }}
      />

  )
}

export async function getStaticProps({ params, preview = false }) {
  const post = await getClient(true).fetch(postQuery, {
    postId: params.postId,
  })

  if (!post) {
    return {
      notFound: true,
    }
  }

  return {
    props: {
      preview: true,
      data: { post },
    },
  }
}

export async function getStaticPaths() {
  const paths = await getClient().fetch(
    groq`*[_type == "post" && defined(slug.current)]{ 'slug': slug.current, 'postId': _id }`
  )

  return {
    paths: paths.map(({ slug, postId }) => ({ params: { slug, postId } })),
    fallback: true,
  }
}

This might be a Firefox specific issue. Sorry for the light issue report, didn't have a lot of time to explore this past weekend. Going to close and maybe update if I find anything else.

source: gharchive/issue

repo: sanity-io/next-sanity

license: MIT

license_type: permissive

license_source: github-api


text:
Update README.md

Aafia Iqbal IGDTUW 1st year IEEE Junior Execom

first open sourcecontribution

source: gharchive/pull-request

repo: sanjay-kv/Open-source-Practice


text:
🛑 Staging is down

In b3fd696, Staging (https://staging.hee.nhs.uk) was down:

HTTP code: 404
Response time: 284 ms

Resolved: Staging is back up in 8843fd2.

repo: sankar-shunmuga/NWP-Monitor-Tool


text:
How can we grab a copy of the original value without the mask being applied?

I'm in a situation where in addition to formatting the value with the mask to display for users (react-input-mask handles this very well), I also need to preserve the raw value of the user input without any formatting.
Is there a recommended way to get this raw value? Would I need to create my own "unmask" method to do that?

any updates/plan for this?

repo: sanniassin/react-input-mask

license: mit

license_source: bigquery


text:
API Documentation: Swagger

Planning to use Swagger for API Documentation in YAML.
See more at Swagger Website
--
@TheDoct0r11 what you think?

You're talking about the rest api? That isn't Yaml, that's either JSON or XML.

No, i'm talking about the API Documentation. Swagger uses YAML to generate the API Documentation.
And Swagger is used for API Documentation, can also used for the REST Documentation. But mainly used for the Classes/Code Documentation xD

I can't see anything on the Swagger website not related to REST.
Also why would one want to write the docs within an extra file?
I'd rather suggest using a tool that uses the documentation that is within the code.
Doxygen is a very common tool.

@BurakDev can do that. With Doxygen

@lai0n will do the Documentation with Doxygen.

Remember.: need to do the HTML API Documentation and In-Code Documentation.


text:
make TournamentsByIds work in batch

part of #691

looks good

authors: rjourde santiaago

repo: santiaago/gonawin

license: isc


text:
建议加入侧边栏的 Tag 属性和样式

Is your feature request related to a problem? Please describe.
需要侧边栏的每个条目可以自定义不同的标签。
Describe the solution you'd like
可以给侧边栏的每个条目加入一个圆角的标签，可以定义条目的标签内容，可以显示 开发中、已弃用等不同的状态，并且可以使用不同的颜色。
Describe alternatives you've considered
No response
Additional context
No response
Validations

[X] Read the docs.
[X] Read the Contributing Guidelines.
[X] Check that there isn't already an issue that asks for the same feature to avoid creating a duplicate.

很好的建议，可以支持


text:
Tags list

[x] Tags list, searchable with count, tag status, description, id and user
[x]  Fetch user image from UserComponent

I understand your changes. However, I think some changes broke the ellipsis truncation of : users names, tags description, tags users name and tags id

I understand your changes. However, I think some changes broke the ellipsis truncation of : users names, tags description, tags users name and tags id

Yes indeed!
I just fixed this.
Thanks for reporting.
Let me know if I broke something else.

The tag's user's name still goes off the screen.

This is because the ellipsizeMode property of the Text component needs a size to know when to truncate
Having two flex items that both need to be truncated is a behaviour I only managed to have by doing the following:

Give a width to the userContainer

Add flexDirection:row and justifyContent:flex-end so that the user name is aligned to the right of the screen when there is still space

I have the exact same behavior on Cars inside the header of CarComponent with the car name on the right on the license plate on the right

Yes I know, that's okay, I just forgot this one ;)

The tag's user's name still goes off the screen

Just pushed my changes, let me know.
Double check with the car styling.
Thanks!

repo: sap-labs-france/ev-mobile


text:
users - phone numbers - accept null or empty string as well

minor change to make it possible to clear the phone numbers

@Ninjeneer Could you please check all your changes?
Thanks!

repo: sap-labs-france/ev-server


text:
Fetch Data from Public API to Your AppGyver Application

Tutorials: https://developers.sap.com/tutorials/appgyver-fetch-data.html
The correct answer set for the last step (step 5) of the tutorial is actually "incorrect" as the app logic is set to fetch the data from the API only when a barcode is scanned.

Hi - thanks for your comment. I've just read the tutorial again and the correct answer is "Only when a barcode is scanned", so I'm not sure I follow your point here?

It's weird because, in my case I was get an "incorrect answer" message every time I selected that one. I only got it to work after selecting "Every five seconds", that's why I thought it was accepting and incorrect answer. Really can't explain how it happened.

authors: ale-biagi heytombeck

repo: sap-tutorials/Tutorials


text:
Errors will happen when upgrading the libraries

An error will happen when upgrading libraries Masterminds/sprig,_prometheus/client_golang_and coreos/ignition:
For example----
github.com/prometheus/client_golang
-Latest Version: v1.7.1   (Latest commit fe7bd95 17 days ago)
-Where did you use it:
https://github.com/sapcc/kubernikus/search?q=prometheus%2Fclient_golang%2Fprometheus&unscoped_q=prometheus%2Fclient_golang%2Fprometheus
-Detail:

github.com/prometheus/client_golang/go.mod

module github.com/prometheus/client_golang
require (
	github.com/beorn7/perks v1.0.1
	github.com/cespare/xxhash/v2 v2.1.1
	…
)
go 1.11

github.com/prometheus/client_golang/prometheus/desc.go

package Prometheus
import (
	"github.com/cespare/xxhash/v2"
	…
)

This problem was introduced since prometheus/client_golang v1.2.0 . . Now you used the version v0.9.0. If you try to upgrade  prometheus/client_golang to version v1.2.0 and above, you will get an error--- no package exists at "github.com/cespare/xxhash/v2"
Similar issues can also happen when upgrading libraries Masterminds/sprig, and coreos/ignition.
I investigated the libraries'  (prometheus/client_golang, Masterminds/sprig and coreos/ignition)  release information and found the root cause of this issue is that----

These dependencies all added Go modules in the recent versions.

They all comply with the specification of "Releasing Modules for v2 or higher" available in the Modules documentation. Quoting the specification:

A package that has migrated to Go Modules must include the major version in the import path to reference any v2+ modules. For example,  Repo github.com/my/module migrated to Modules on version v3.x.y.  Then this repo should declare its module path with MAJOR version suffix "/v3"  (e.g., module github.com/my/module/v3), and its downstream project should use "github.com/my/module/v3/mypkg" to import this repo’s package.

This "github.com/my/module/v3/mypkg" is not the physical path. So earlier versions of Go (including those that don't have minimal module awareness) plus all tooling (like dep, glide, govendor, etc) don't have minimal module awareness as of now and therefore don't handle import paths correctly.

Note: creating a new branch is not required. If instead you have been previously releasing on master and would prefer to tag v3.0.0 on master, that is a viable option. (However, be aware that introducing an incompatible API change in master can cause issues for non-modules users who issue a go get -u given the go tool is not aware of semver prior to Go 1.11 or when module mode is not enabled in Go 1.11+).
Pre-existing dependency management solutions such as dep currently can have problems consuming a v2+ module created in this way. See for example dep#1962.
https://github.com/golang/go/wiki/Modules#releasing-modules-v2-or-higher

Suggested solutions
1. Migrate to Go Modules.
Go Modules is the general trend of ecosystem, If you want a better upgrade package experience, migrating to Go Modules is a good choice.
2. Keep using the dependency manage tool (like dep, glide, govendor, etc).
Because the import paths have different meanings between the projects adopting module mechanism and the non-module mechanism.

https://github.com/golang/go/wiki/Modules#semantic-import-versioning
https://golang.org/cmd/go/#hdr-Module_compatibility_and_semantic_versioning
https://github.com/golang/go/wiki/Modules#releasing-modules-v2-or-higher

If you prefer to use the dependencies manage tool (like dep, glide, govendor, etc), a textbook example provided by repo github.com/moby/moby can prevent this type of issues.
https://github.com/moby/moby/blob/master/VENDORING.md
https://github.com/moby/moby/blob/master/vendor.conf
In the vendor directory, github.com/moby/moby adds the /vN subdirectory in the corresponding dependencies.
This will help more downstream modules to work well with your package.
Do you plan to upgrade the libraries in near future?
Hope this issue report can help you ^_^
Thank you very much for your attention.
Best regards,
Kate

@jknipper  @databus23  Could you help me review this issue? Thx :p
By the way, have you ever encountered such errors when upgading the libraries?

repo: sapcc/kubernikus


text:
panic: runtime error: index out of range [-9223372036854775808]

We have an lfs repo with 60.000+ files. I am seeing an issue where some files are correctly downloaded and cached, but the program crashes after some files.
Output looks like this:
level=info ts=2020-06-23T12:06:03.1992193Z event=fetched oid=9230f90f3b3f461400dd00fdb3c2257c22332466bb9ad0c8476e7a23d46c458a took=567.9984ms downloaded=45180/45180 rate="852 KB/s"
level=info ts=2020-06-23T12:06:03.2002201Z event=served oid=9230f90f3b3f461400dd00fdb3c2257c22332466bb9ad0c8476e7a23d46c458a source=fresh took=570.0011ms size=45180 rate="79 KB/s"
level=info ts=2020-06-23T12:06:03.21022Z event=serving oid=63b5bca91e6758cd576111976ed5c69887e2a57b074db0aca53a5843ebecc9ff source=fresh
level=info ts=2020-06-23T12:06:03.21022Z event=fetching oid=63b5bca91e6758cd576111976ed5c69887e2a57b074db0aca53a5843ebecc9ff
panic: runtime error: index out of range [-9223372036854775808]
goroutine 130 [running]:
github.com/git-lfs/git-lfs/tools/humanize.FormatByteRate(0xb07c, 0x0, 0x9f61a0, 0x0)
/home/travis/gopath/pkg/mod/github.com/git-lfs/git-lfs@v2.5.2+incompatible/tools/humanize/humanize.go:160 +0x318
github.com/saracen/lfscache/server.(*Server).fetch.func1(0xc0001926f0, 0xc0008efee0, 0xc0000d4180, 0xc000188130, 0x40, 0xbfb499eacc970048, 0x40e92108d, 0x9f61a0, 0xb07c, 0xc0008effd0)
/home/travis/gopath/src/github.com/saracen/lfscache/server/server.go:405 +0x7d
github.com/saracen/lfscache/server.(*Server).fetch(0xc0000d4180, 0x272f0240, 0xc0001925a0, 0xc000188130, 0x40, 0xc0000a4000, 0x50, 0xb07c, 0xc000192540, 0x0, ...)
/home/travis/gopath/src/github.com/saracen/lfscache/server/server.go:445 +0x584
created by github.com/saracen/lfscache/server.(*Server).serve
/home/travis/gopath/src/github.com/saracen/lfscache/server/server.go:354 +0x6b3
Update 1:
Version is: 0.1.3, commit 848d795dde4930919bec1f0b9f7b6061863f3a33, built at 2020-06-20T14:23:14Z

@llob Thank you for reporting this.
Can you try and see if 0.1.4 works for you?

authors: llob saracen

repo: saracen/lfscache


text:
[Error] Could not build wheels for aiohttp

when trying to use chessdotcom api on fedora OS I've come to the error that with ever way of doing "pip3 install chess.com" the error is "ERROR: Could not build wheels for aiohttp, which is required to install pyproject.toml-based projects".
Then I've tried the following which didn't help:

pip3 install wheel (just to be very safe)
pip3 install --upgrade pip setuptools wheel
pip3 install aiohttp (This actually worked without error)

Thanky you for help in advance

I did a bad thing and installed my python library's globally on my raspberry pi, even though it told me not to, but that shouldn't be why I'm having problems. I'm in dependency hell right now. When I try to run one of the example scripts I get this error.
/usr/local/lib/python3.11/dist-packages/requests/init.py:109: RequestsDependencyWarning: urllib3 (1.26.12) or chardet (5.1.0)/charset_normalizer (2.0.12) doesn't match a supported version!
warnings.warn(
I can't find the right versions for these things anywhere!


text:
Fix bugs.

I fixed some small errors when referring to dataset names. With this change, create_unified_dataset.py runs correctly for crowdflower and dailydialog datasets.

👍 Thanks for the pull request. I'll have a look.
I plan update this repo over the weekend with more datasets and a nicer CLI.

Had time to look at it now.
I wouldn't consider these bugs, as the source fields in the resulting dataset are just arbitrary names that aren't guaranteed to correspond to any folders in datasets/, but I guess it's better for consistency to rename them.

authors: dcaled sarnthil

repo: sarnthil/unify-emotion-datasets


text:
🛑 Tian is down

In ac50ae9, Tian (https://www.tianaix.com) was down:

HTTP code: 0
Response time: 0 ms

Resolved: Tian is back up in 36931b7 after 14 minutes.

repo: sarpaykent/uptime


text:
Shell Sort Added

#65 sorting algo added

Please resolve the merge conflicts :)


text:
Changed the binary site path to download from but npm adds a path

NPM version (npm -v): 6.4.1
Node version (node -v): 10.14.1
Node Process (node -p process.versions):
{
http_parser: '2.8.0',
node: '10.14.1',
v8: '6.8.275.32-node.36',
uv: '1.23.2',
zlib: '1.2.11',
ares: '1.14.0',
modules: '64',
nghttp2: '1.34.0',
napi: '3',
openssl: '1.1.0j',
icu: '62.1',
unicode: '11.0',
cldr: '33.1',
tz: '2018e'
}
Node Platform (node -p process.platform): linux
Node architecture (node -p process.arch): x64
node-sass version (node -p "require('node-sass').info"): 4.9.3*
npm node-sass versions (npm ls node-sass): N/A

*the issue is trying to download node-sass
Basically, I can't access github for node-sass from this corporate network on my virtualmachine. However, we have a proxy where node-sass is located: http://our-proxy.com/respository/node-sass
This repo has version 4.9.3 in it, but it's a tar.gz file. I'm not sure if npm doesn't like that.
I've set my SASS_BINARY_SITE to the node-sass location on the proxy and npm acknowledges it:
Downloading binary from https://our-proxy/repository/npm-proxy/node-sass/v4.9.3/linux-x64-64_binding.node
Cannot download "https://our-proxy/repository/npm-proxy/node-sass/v4.9.3/linux-x64-64_binding.node": tunneling socket could not be established, statusCode=405
When I run npm install, install.js is adding the "v4.9.3/linux-x64-64_binding.node" to the end of the site path so it basically can't find the download because nothing exists at that path.
So it there a way to also change the download path that npm is searching our proxy site for? OR is there a way to not try to download node-sass at all because this is mainly for resolving giant globs of errors that don't necessarily affect the rest of the build.

Ended up using a locally downloaded version of node-sass and pointing npm to it with
SASS_BINARY_PATH and SASS_BINARY_DIR. Needed to set both for it to work.

repo: sass/node-sass


text:
Grafana not accessible through its ingress

In the sample file: monitoring/samples/azure-deployment there are ingresses set up for prometheus, alertmanager and grafana.  Using the sample file (changing hostnames as directed) I could not access grafana from its ingress address (but I could access prometheus and alertmanager).  What I found is that the section of this file pertaining to grafana is missing the following two lines that appear in both the prometheus and alertmanager sections:
annotations:
  kubernetes.io/ingress.class: nginx

Once I added those two lines to the grafana section and re-deployed I am able to access the grafana ingress.   If I'm missing something and have approached this incorrectly, please let me know -- but I think this could be an issue.

SASBXS:  Thanks for reporting this.  I believe you have correctly identified the issue and the right solution.  I will add an item on our To Do list to update our sample.

authors: gsmith-sas sasbxs


text:
Feedback from pre-demo demo with project stakeholders

Master issue for tracking changes based on feedback from demo/discussion on 18 Feb 2015

@stuartf as usual, review as little or as much as you prefer. This is the code that Clay is demoing on Monday

repo: sathomas/STEM


text:
Dotnet mattkeenum

I've made several modifications to the dotnet bindings.
Notable changes:

I've added a Prerun class to help constrain how preruns should be initialized
I added a test to ensure the new Prerun is working as expected
Updated the endpoint for the west data center
Updated EdgeVersions to match what Sauce Labs is currently offering
Updated Safari Versions/Platforms to match what Sauce Labs is currently offering
Added several overloaded constructors for the SauceSession class
Simplified the SauceSession class to be more DRY
Finished the Sauce Driver class
Several refactorings across other classes

 Here is an overview of what got changed by this pull request:

Issues
======
- Added 7

Complexity increasing per file
==============================
- dotnet/Simple.Sauce/IncorrectSafariVersionException.cs  1
- dotnet/Simple.Sauce/JsonUtils.cs  1
- dotnet/Simple.Sauce/SauceDriver.cs  1
- dotnet/Simple.Sauce/SauceOptions.cs  2
- dotnet/SimpleSauce.Test/PreRunTests.cs  1
- dotnet/Simple.Sauce/PreRun.cs  1

See the complete overview on Codacy

 Here is an overview of what got changed by this pull request:

Complexity increasing per file
==============================
- dotnet/SimpleSauce.Test/PreRunTests.cs  1
- dotnet/Simple.Sauce/JsonUtils.cs  1
- dotnet/Simple.Sauce/PreRun.cs  1
- dotnet/Simple.Sauce/IncorrectSafariVersionException.cs  1
- dotnet/Simple.Sauce/SauceOptions.cs  2
- dotnet/Simple.Sauce/SauceDriver.cs  1

See the complete overview on Codacy

Excellent work here @MattKeenum 👏 This is a huge PR. Can you please break it up into a few smaller PRs that we can address one at a time. Otherwise, we might be dealing with this code review for a while 😨

Excellent work here @MattKeenum 👏 This is a huge PR. Can you please break it up into a few smaller PRs that we can address one at a time. Otherwise, we might be dealing with this code review for a while 😨

No problem. Is there a specific way you want me to break it up? Is per file the best? Or more per module?

@MattKeenum smaller is better 👍  here are a few super easy ones:

dotnet/Simple.Sauce/Browser.cs
dotnet/Simple.Sauce/DataCenter.cs
dotnet/Simple.Sauce/EdgeVersion.cs
dotnet/Simple.Sauce/Platforms.cs
See if you can find a few more simple ones like that. Afterwards, it gets more hairy as we're working on a large update to the API. So I'll need to work and coordinate with you to figure that out

@MattKeenum smaller is better 👍 here are a few super easy ones:

dotnet/Simple.Sauce/Browser.cs
dotnet/Simple.Sauce/DataCenter.cs
dotnet/Simple.Sauce/EdgeVersion.cs
dotnet/Simple.Sauce/Platforms.cs
See if you can find a few more simple ones like that. Afterwards, it gets more hairy as we're working on a large update to the API. So I'll need to work and coordinate with you to figure that out

So do you want me to break these down as individual pull requests?

authors: MattKeenum nadvolod


text:
Added Message to Frontend

Added Message to Frontend on Signin and Signup Page
Description
Now when user comes to sign-in and signup he is shown the message that is given by the server so that he can see whether the action performed is completed or not.
Related Issue
Fixes #49
Changes Made

Added a State which renders the message dynamically
Added a styled div
Added red/green colour to the message depending on which action is being taken

Checklist

[x] I have tested my code and it works as expected.
[x] I have added/updated documentation where necessary.
[x] I have included tests for new features.
[x] I have followed the project's coding standards.

@vverma022 create the branch name proper and create the PR proper to develop branch


text:
Transform the addon into a simple Go server (take two)

Compared to #4, this has the following differences:

Added devcontainer setup for local testing. See https://developers.home-assistant.io/docs/add-ons/testing/ for the testing setup.
Added GitHub workflows for building, scanning, and linting
Switched to structured logging
Changed starargs to a map - the integration should do the splitting if the user provides a single string.
Additional validation to prevent path traversal.

I’m have this in my dev environment with the updated integration and it’s working well so far. Gonna test a few things and then merge these changes once I push the integration updates. Thanks for your hard work and you got me to learn a bit of Go in the process lol.

authors: IngmarStein savdagod

repo: savdagod/ha-addons


text:
Hom to set local data and DateFormat

calendar_view.init(lastYear.time, nextYear.time, SimpleDateFormat("MMMM YYYY", Locale("th","th")))
.inMode(CalendarPickerView.SelectionMode.RANGE)
.withSelectedDate(Date())
I'm set this is not 2568

Please use init(Date minDate, Date maxDate, TimeZone timeZone, Locale locale, DateFormat monthNameFormat) to specify different locale and timeZone, with custom month name format

authors: KreephetSathotnluk savvisingh

repo: savvisingh/DateRangePicker


text:
feat: properly handle transaction hashes

Feature Request
Describe the Feature Request
Currently, we don't handle discrepancies between EVM transaction hashes vs. Starknet transaction hashes. We should programmatically "know" whether a user is manipulating starknet tx hashes or evm tx hashes, and return the correct hash.
Example:
1.
User calls getTransactionReceipt, they will use an EVM tx hash, as this is the return value they get when calling eth_sendRawTransaction.
Thus, we need a deterministic mapping between an EVM tx hash and the resulting Starknet tx hash

Kakarot MUST expose EVM-type transaction hashes (tx receipt, etc.)
Kakarot MUST be able to take in an EVM tx hash and call the corresponding Starknet tx hash (execute_at_address tx hash)

Closing this as it was decided in 21 Feb community call to keep starknet tx hashes

repo: sayajin-labs/kakarot-rpc


text:
[Migration] SSR and Server Actions

Implement SSR and Server Actions
Description:
Currently The Next.js Branch uses regular React.js Like Client Side rendering with useState, useEffect hooks and authentication System using Local storage.

Replace localStorage with Cookie based authentication
Implement Server Side Rendering (SSR). Fetch the data from backend in server components, then pass it to client components through props.
Implement Server actions on form submissions instead of regular API calls from client side.
Implement proper loading state on server components and form submissions

will u assign me this issue i can work on it

will u assign me this issue i can work on it

Sure, go ahead

repo: sayakongit/sangnet


text:
Add this StackTrace concept

https://blog.vanillajava.blog/2021/12/unusual-java-stacktrace-extends.html?m=1&msclkid=99f62309d00011ecad88b694d42dc676

Resolved by #26

repo: sbabcoc/Java-Utils


text:
Macro testmails come through

I just installed MacroMilter on my Centos7 box and configured postfix to use it as smtpd_milter. I followed the description for installation on opensuse provided here.
The log file tells me that MacroMilter is started
2017-01-12 09:57:48,236 -     INFO: Starting mraptor_milter v3.0 - listening on inet:3690@127.0.0.1
2017-01-12 09:57:48,236 -    DEBUG: Python version: 2.7.5 (default, Nov  6 2016, 00:28:07)
[GCC 4.8.5 20150623 (Red Hat 4.8.5-11)]

process list tells me its up an running
postfix  17984  0.0  0.4 316452 15560 ?        Sl   09:52   0:00 /usr/bin/python /etc/macromilter/macromilter.py

When a mail arrives it logs to macromilter.log this one and only line (IP address redacted)
2017-01-12 09:58:31,021 -    DEBUG: connect from [XX.YY.26.120] at ('XX.YY.26.120', 50359)

The config tells macromilter to reject "infected" files. But even if I pack "rechnung-postmaster789.doc" from tests in this repo the mails comes through to my mailbox.
Any idea what I did wrong? Should there not be more loglines (at least with DEBUG level)?
Thanks
tobi

Hey,
normally the debug level provides more then this line :) .
I'll investigate this behavior - fist I should setup a CentOS with the same python version.
Do you attach the file in a zip container? Or plain as doc?
Thanks for contributing and testing !!
Stephan

I attached the file plain as doc

If you need a testbox (Centos7) just let me know. If you like I can set one up for you on my server

Thanks. But I've already installed the test system. Can you please stop the server and  start the macromilter.py with: python macromilter.py . Are any error or exception at the stdout ?

it starts without any error if I use python macromilter.py

Ok - I've tested the installation and can't reproduce the failure.
My system: CentOS 7 3.10.0-514.el7.x86_64 - Python version: 2.7.5 - GCC 4.8.5 20150623 (Red Hat 4.8.5-11)
Please test with the TestFile.
Do you install the pip install configparser?

yep configparser is installed
pip install configparser
Requirement already satisfied: configparser in /usr/lib/python2.7/site-packages

I tried with your TestFile. It gets through to my mailbox. Even clamav catches the macro :-)
And as before just one log line when processing the testmail
2017-01-13 16:39:44,708 -    DEBUG: connect from [XX.YY.26.120] at ('XX.YY.26.120', 51768)

Ok, that's strange. Do you use other smtpd-milters? Can you please turn off all others?
I've to alter the macro :-) - but my ClamAV and TrendMicro (OS) don't recognize the file as "Malware". Do you use the sanesecurity signatures at the clamav?

Nope no other smtpd-milters on that server. Yap the sanesecurity rules caught it and not clamav alone.

I think, I'm able to reproduce this here (partially):
2017-10-07 01:11:43,634 -    DEBUG: connect from localhost at ('::1', 52210, 0, 0)
2017-10-07 01:11:43,698 -    DEBUG: [2] Content-type: 'multipart/mixed'
2017-10-07 01:11:43,698 -    DEBUG: [2] Content-type: 'text/plain'
2017-10-07 01:11:43,699 -    DEBUG: [2] Analyzing attachment None
2017-10-07 01:11:43,699 -    DEBUG: [2] Content-type: 'application/zip'
2017-10-07 01:11:43,700 -    DEBUG: [2] Analyzing attachment 'rechnung-postmaster789.zip'
2017-10-07 01:11:43,700 -    DEBUG: Find Attachment with archive extension - File name: rechnung-postmaster789.zip
2017-10-07 01:11:43,701 -     INFO: File in zip detected! Name: rechnung-postmaster789.doc - check for VBA
2017-10-07 01:11:43,703 -    DEBUG: The attachment 'rechnung-postmaster789.zip' is clean.

And:
2017-10-07 01:26:26,638 -    DEBUG: connect from localhost at ('::1', 52546, 0, 0)
2017-10-07 01:26:26,686 -    DEBUG: [6] Content-type: 'multipart/mixed'
2017-10-07 01:26:26,687 -    DEBUG: [6] Content-type: 'text/plain'
2017-10-07 01:26:26,687 -    DEBUG: [6] Analyzing attachment None
2017-10-07 01:26:26,688 -    DEBUG: [6] Content-type: 'application/zip'
2017-10-07 01:26:26,688 -    DEBUG: [6] Analyzing attachment 'rechnung-postmaster789.doc.zip'
2017-10-07 01:26:26,688 -    DEBUG: Find Attachment with archive extension - File name: rechnung-postmaster789.doc.zip
2017-10-07 01:26:26,689 -     INFO: File in zip detected! Name: rechnung-postmaster789.doc - check for VBA
2017-10-07 01:26:26,691 -    DEBUG: The attachment 'rechnung-postmaster789.doc.zip' is clean.

But:
2017-10-07 01:14:58,729 -    DEBUG: connect from localhost at ('::1', 52214, 0, 0)
2017-10-07 01:14:58,788 -    DEBUG: [3] Content-type: 'multipart/mixed'
2017-10-07 01:14:58,788 -    DEBUG: [3] Content-type: 'text/plain'
2017-10-07 01:14:58,788 -    DEBUG: [3] Analyzing attachment None
2017-10-07 01:14:58,788 -    DEBUG: [3] Content-type: 'application/zip'
2017-10-07 01:14:58,788 -    DEBUG: [3] Analyzing attachment 'zipwithinfectedandnotinfectedword.zip'
2017-10-07 01:14:58,789 -    DEBUG: Find Attachment with archive extension - File name: zipwithinfectedandnotinfectedword.zip
2017-10-07 01:14:58,789 -     INFO: File in zip detected! Name: rechnung-postmaster789.doc - check for VBA
2017-10-07 01:14:58,797 -     INFO: File in zip detected! Name: clean_wordfile.docx - check for VBA
2017-10-07 01:14:58,798 -    DEBUG: File Added 9cec615ebb8dd00640103d73f1cad9a991959364056aedf38163f97d391ecb9f873fe1892d136653afaf6d42572e6b7bb556973e6d46a0fc57b354dd713bc54b
2017-10-07 01:14:58,799 -  WARNING: [3] The attachment 'zipwithinfectedandnotinfectedword.zip' contains a suspicious macro. REJECT

And the cause is likely somewhere here:
SHA256 (zipwithinfectedandnotinfectedword.zip/rechnung-postmaster789.doc) = 451c28e505b2051c630914185dc6c2e0460ae30b219e02fdb6e7990935bf6981
SHA256 (rechnung-postmaster789.zip/rechnung-postmaster789.doc) = c4f72eb6f8506a6653e57bf0b8cfd0889bbb875e663104b397cd15b75c60e61e

Two different checksums…feels like you are shipping a clean and an infected file – having both the same name. The following is also a bit confusing (duplicated tree, but different checksums):
# find -name "*.zip" | xargs sha256sum
977712e766966dbe0ade082336c3a82081957cc69a7ea45469163c93bf787686  ./macromilter/tests/test_mails/clean_wordfile.zip
5059c6383cc280b15fc1c6a5e401d06825d533c5e90db6e75e845fa4fbbff829  ./macromilter/tests/test_mails/rechnung-postmaster789.doc.zip
f9d70d02f61de25d6bbab0d7af04c145b6c5bb1ce32c8c59291bfd655beaac97  ./macromilter/tests/test_mails/zipwithinfectedandnotinfectedword.zip
c208ee14674f7939547f53eda21323cc06150d84917bd98587b289e85fbc7eb1  ./tests/test_mails/TestDoc.zip
977712e766966dbe0ade082336c3a82081957cc69a7ea45469163c93bf787686  ./tests/test_mails/clean_wordfile.zip
c2893380e4d075b5be77b0c700c39cf2e7fe561c4a676757df73fce455bcc3e2  ./tests/test_mails/rechnung-postmaster789.zip
f9d70d02f61de25d6bbab0d7af04c145b6c5bb1ce32c8c59291bfd655beaac97  ./tests/test_mails/zipwithinfectedandnotinfectedword.zip
#

authors: jahlives robert-scheck sbidy

repo: sbidy/MacroMilter


text:
WAVE metadata bug in TagLib

I have another metadata bug report and this one seems to be in the TagLib library. Here's the strack trace:
Process:         Sonora [35038]
Path:            /Applications/Sonora.app/Contents/MacOS/Sonora
Identifier:      com.iktm.Sonora
Version:         0.71 (0.71)
Code Type:       X86-64 (Native)
Parent Process:  launchd [188]

Date/Time:       2012-01-26 16:22:52.075 -0500
OS Version:      Mac OS X 10.7.2 (11C74)
Report Version:  9

Crashed Thread:  5  Dispatch queue: com.apple.root.default-priority

Exception Type:  EXC_ARITHMETIC (SIGFPE)
Exception Codes: EXC_I386_DIV (divide by zero)

Application Specific Information:
objc[35038]: garbage collection is OFF

......

Thread 5 Crashed:: Dispatch queue: com.apple.root.default-priority
0   org.kde.taglib                	0x000000010bd22bea TagLib::RIFF::WAV::Properties::read(TagLib::ByteVector const&) + 362
1   org.kde.taglib                	0x000000010bd22cb2 TagLib::RIFF::WAV::Properties::Properties(TagLib::ByteVector const&, unsigned int, TagLib::AudioProperties::ReadStyle) + 92
2   org.kde.taglib                	0x000000010bd2273d TagLib::RIFF::WAV::File::read(bool, TagLib::AudioProperties::ReadStyle) + 675
3   org.kde.taglib                	0x000000010bd22848 TagLib::RIFF::WAV::File::File(TagLib::IOStream*, bool, TagLib::AudioProperties::ReadStyle) + 116
4   org.sbooth.AudioEngine        	0x000000010b8fae5f WAVEMetadata::ReadMetadata(__CFError**) + 153
5   org.sbooth.AudioEngine        	0x000000010b8f3678 AudioMetadata::CreateMetadataForURL(__CFURL const*, __CFError**) + 754

And the offending file: http://dl.dropbox.com/u/65903/samplewav.wav. I'm using the TagLib build that's in the Frameworks.zip in SFBAudioEngine's downloads.

The crash occurs because the file's bit depth is less than 8.  The fix shouldn't be too hard, and the bug is definitely in TagLib.

See https://github.com/taglib/taglib/pull/25 for the fix

Thanks :)

authors: indragiek sbooth

repo: sbooth/SFBAudioEngine


text:
SBT 1.0.0 is missing in ivy-releases

I am accessing sbt behind proxy, and I wanted to upgrade to sbt 1.0.0, however the resolution of the sbt itself failed.
For setting up my proxy, I followed this page:
http://www.scala-sbt.org/1.0/docs/Proxy-Repositories.html
And when looking at (what I think) the right repo, I cannot see sbt 1.0.0:
http://dl.bintray.com/typesafe/ivy-releases/org.scala-sbt/sbt/

sbt 1+ is released on Maven Central: http://repo1.maven.org/maven2/org/scala-sbt/sbt/1.0.0/

Mmm, then how can sbt resolve it if it is running behind the proxy?

Make sure that your proxy repository is configured for Maven Central.

It is, and it still fails
I have added maven central as mvn-releases proxy though, maybe that is why sbt fails.
Getting org.scala-sbt sbt 1.0.0 ...

:: problems summary ::
:::: WARNINGS
		module not found: org.scala-sbt#sbt;1.0.0

	==== local: tried

	  ~/.ivy2/local/org.scala-sbt/sbt/1.0.0/ivys/ivy.xml

	  -- artifact org.scala-sbt#sbt;1.0.0!sbt.jar:

	 ~/.ivy2/local/org.scala-sbt/sbt/1.0.0/jars/sbt.jar

	==== my-ivy-proxy-releases: tried

	  https://myproxy.jfrog.io/myproxy/sbt-proxy/org.scala-sbt/sbt/1.0.0/ivys/ivy.xml

	==== my-maven-proxy-releases: tried

	  https://myproxy.jfrog.io/myproxy/mvn-release/org/scala-sbt/sbt/1.0.0/sbt-1.0.0.pom

	  -- artifact org.scala-sbt#sbt;1.0.0!sbt.jar:

	  https://myproxy.jfrog.io/myproxy/mvn-release/org/scala-sbt/sbt/1.0.0/sbt-1.0.0.jar

		::::::::::::::::::::::::::::::::::::::::::::::

		::          UNRESOLVED DEPENDENCIES         ::

		::::::::::::::::::::::::::::::::::::::::::::::

		:: org.scala-sbt#sbt;1.0.0: not found

		::::::::::::::::::::::::::::::::::::::::::::::

See how the jar is found, but somehow SBT fails to resolve it:
==== my-maven-proxy-releases: tried

	  https://myproxy.jfrog.io/myproxy/mvn-release/org/scala-sbt/sbt/1.0.0/sbt-1.0.0.pom

	  -- artifact org.scala-sbt#sbt;1.0.0!sbt.jar:

	  https://myproxy.jfrog.io/myproxy/mvn-release/org/scala-sbt/sbt/1.0.0/sbt-1.0.0.jar

		::::::::::::::::::::::::::::::::::::::::::::::

		::          UNRESOLVED DEPENDENCIES         ::

		::::::::::::::::::::::::::::::::::::::::::::::

		:: org.scala-sbt#sbt;1.0.0: not found

		::::::::::::::::::::::::::::::::::::::::::::::

And by following the path, I can clearly see it

So, the issue is with the credentials. Apparently the 0.13 way for providing credentials is not sufficient. In 0.13 I had:
credentials += Credentials(Path.userHome / ".sbt" / ".credentials") in ~/.sbt/0.13/plugins/credentials.sbt
But sbt 1.0.0 wasn't able to read the same line from: ~/.sbt/1.0/plugins/credentials.sbt
I had to call sbt with: SBT_CREDENTIALS=~/.sbt/.credentails; sbt compile for the credentials to be loaded.
Is this a know change/bug?
@dwijnand

I'm surprised you say that ~/.sbt/0.13/plugins/credentials.sbt works, because it should be ~/.sbt/0.13/credentials.sbt, which for sbt 1 is ~/.sbt/1.0/credentials.sbt. Does that fix it?

Yup, putting credentials.sbt directly under 1.0 works. Maybe another thing to add to the migration notes?

Nothing changed here. If you go to an sbt 0.13 build and use inspect credentials you should see where you're getting them. For example mine:
> inspect credentials
[info] Task: scala.collection.Seq[sbt.Credentials]
[info] Description:
[info] 	The credentials to use for updating and publishing.
[info] Provided by:
[info] 	{file:/s/t-a/}t/*:credentials
[info] Defined at:
[info] 	/Users/dnw/.sbt/0.13/credentials.sbt:2
[info] 	/Users/dnw/.sbt/0.13/credentials.sbt:5
[info] 	/Users/dnw/.sbt/0.13/credentials.sbt:7
[info] Dependencies:
[info] 	*:organization
[info] Reverse dependencies:
[info] 	*:ivySbt
[info] Delegates:
[info] 	*:credentials
[info] 	{.}/*:credentials
[info] 	*/*:credentials
[info] Related:
[info] 	*/*:credentials

Strange, I get the following:
inspect credentials
[info] Task: scala.collection.Seq[sbt.Credentials]
[info] Description:
[info] 	The credentials to use for updating and publishing.
[info] Provided by:
[info] 	*/*:credentials
[info] Defined at:
[info] 	(sbt.Defaults) Defaults.scala:100
[info] Reverse dependencies:
[info] 	adgear-identifyd/*:ivySbt
[info] Delegates:
[info] 	adgear-identifyd/*:credentials
[info] 	{.}/*:credentials
[info] 	*/*:credentials
[info] Related:
[info] 	*/*:credentials

I also have this line in my /usr/local/etc/sbtopts:
-Dsbt.boot.credentials=~/.sbt/.credentials

So, if I remove the entry in sbtopts the launcher fails to download the specified sbt version from artifactory. And if I move credentials from 0.13/plugins/ to 0.13 artifactory fails to download the dependencies!

Ah, now I understand. You need the credentials to download sbt. Now ~/.sbt/0.13/plugins/credentials.sbt makes sense.

The IntelliJ IDEA Scala plugin uses Bintray to present a list of available SBT versions in the new project wizard. See https://github.com/JetBrains/intellij-scala/blob/42e1a01bef54aa21a50e9938277f9759eb6565b9/src/org/jetbrains/plugins/scala/project/Versions.scala#L64

authors: amanjpro dwijnand martinoconnor

repo: sbt/sbt


text:
Errors at run lila

[error] a.i.TcpListener - Bind failed for TCP channel on endpoint [/0.0.0.0:9663]
java.net.BindException: [/0.0.0.0:9663] Address already in use
at java.base/sun.nio.ch.Net.bind0(Native Method)
at java.base/sun.nio.ch.Net.bind(Net.java:469)
at java.base/sun.nio.ch.Net.bind(Net.java:458)
at java.base/sun.nio.ch.ServerSocketChannelImpl.bind(ServerSocketChannelImpl.java:220)
at java.base/sun.nio.ch.ServerSocketAdaptor.bind(ServerSocketAdaptor.java:88)
at akka.io.TcpListener.liftedTree1$1(TcpListener.scala:60)
at akka.io.TcpListener.(TcpListener.scala:57)
at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
at java.base/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
[error] akka.stream.impl.io.ConnectionSourceStage$$anon$1$$anon$2: Bind failed because of java.net.BindException: [/0.0.0.0:9663] Address already in use
[error] Caused by: java.net.BindException: [/0.0.0.0:9663] Address already in use
[error] 	at java.base/sun.nio.ch.Net.bind0(Native Method)
[error] 	at java.base/sun.nio.ch.Net.bind(Net.java:469)
[error] 	at java.base/sun.nio.ch.Net.bind(Net.java:458)
[error] 	at java.base/sun.nio.ch.ServerSocketChannelImpl.bind(ServerSocketChannelImpl.java:220)
[error] 	at java.base/sun.nio.ch.ServerSocketAdaptor.bind(ServerSocketAdaptor.java:88)
[error] 	at akka.io.TcpListener.liftedTree1$1(TcpListener.scala:60)
[error] 	at akka.io.TcpListener.(TcpListener.scala:57)
[error] 	at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
[error] 	at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
[error] 	at java.base/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
[error] 	at java.base/java.lang.reflect.Constructor.newInstanceWithCaller(Constructor.java:500)
[error] 	at java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:481)
[error] 	at akka.util.Reflect$.instantiate(Reflect.scala:70)
[error] 	at akka.actor.ArgsReflectConstructor.produce(IndirectActorProducer.scala:101)
[error] 	at akka.actor.Props.newActor(Props.scala:226)
[error] 	at akka.actor.ActorCell.newActor(ActorCell.scala:611)
[error] 	at akka.actor.ActorCell.create(ActorCell.scala:637)
[error] 	at akka.actor.ActorCell.invokeAll$1(ActorCell.scala:511)
[error] 	at akka.actor.ActorCell.systemInvoke(ActorCell.scala:533)
[error] 	at akka.dispatch.Mailbox.processAllSystemMessages(Mailbox.scala:295)
[error] 	at akka.dispatch.Mailbox.run(Mailbox.scala:230)
[error] 	at akka.dispatch.Mailbox.exec(Mailbox.scala:243)
[error] 	at java.base/java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:290)
[error] 	at java.base/java.util.concurrent.ForkJoinPool$WorkQueue.topLevelExec(ForkJoinPool.java:1016)
[error] 	at java.base/java.util.concurrent.ForkJoinPool.scan(ForkJoinPool.java:1665)
[error] 	at java.base/java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1598)
[error] 	at java.base/java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:177)
[error] stack trace is suppressed; run last Compile / run for the full output
[error] (Compile / run) java.lang.reflect.InvocationTargetException

@jasurbek01 Please follow the bug reporting guideline - https://github.com/sbt/sbt/blob/develop/CONTRIBUTING.md#what-to-report.
Looking at the stack trace, all I'm seeing is Akka Stream failing to open port for 9663. Likely the socket is still in TIME-WAIT state. See my server fault answer for the details https://serverfault.com/questions/329845/how-to-forcibly-close-a-socket-in-time-wait/329846#329846. I don't see how this is an sbt issue.


text:
fix foundry gh-actions

Description :

Templatised lint.yaml depending on solidity frameWork option chosen
In foundry gitignore only ignore deployments of 31337.json  and unignore rest all chains.

If we don't do above, when we have deployed contract on other chain (it will be present in broadcast dir) but not in deployments dir which causes the action to fail checkout this example
After unignoring  other chains it started passing checkout example here

Lgtm!

repo: scaffold-eth/create-eth


text:
Add use effect on Balance component for the price

The usdMode flag wasn't working on our Balance component, since the price takes some time to load and we were always setting displayUsdMode to false on the first render (price > 0 condition)
You can test in page.tsx
/* This will always show the Balance in ETH mode, even if we say usdMode */
<Balance address={connectedAddress} usdMode />

This PR adds the missing useEffect (as in EtherInput).

Fix works great!
But I think we need to consider rewriting a bit the logic of the Balance and EtherInput components (in another pull request). Because usdMode prop is basically doesn't mean real mode inside the component because of internal toggling logic. I'm thinking about two options

Rename usdMode to defaultUsdMode and use that value as default in useState. Remove useEffect. (I prefer this)
Remove inner usd/eth logic. Use only usdMode prop (or mode)
Yes, with that options we can't change mode of let's say group of EtherInputs, but not sure we need it.

Also, who remembers why we added that price > 0 condition? Looks like it's redundant

Thanks for the review @rin-st !

who remembers why we added that price > 0 condition?  Looks like it's redundant

The USD mode only makes sense when we have a price for the native currency. If it's loading (or if the fetch fails) it doesn't make sense to show the USD mode... since you won't be able to convert to the native currency (which is what we want for any onchain operation / show balance, etc). So I think that was the reason.

Rename usdMode to defaultUsdMode and use that value as default in useState. Remove useEffect. (I prefer this)

This will only work if we ignore my previous comment (the price condition). I agree that defaultUsdMode might be a better name.

Remove inner usd/eth logic. Use only usdMode prop (or mode)

I don't like this one since it'd require people to do their logic for the basic toggle USD / ETH.

I'm not sure if these components need a refactor, but like you said, it should probably happen in another PR.
I just created this one as a hotfix, to tackle a bug that is currently happening on main (and tried to be consistent with other components)

Thank you for explanation!

I just created this one as a hotfix, to tackle a bug that is currently happening on main (and tried to be consistent with other components)

Agree, lgtm!

authors: carletex rin-st


text:
LocalDate and Instant parsers

Implemented parse method for java.time.Instant
Implemented parse method for java.time.LocalDate
Fixed bug with toString method in java.time.Instant

Fixes: https://github.com/scala-js/scala-js-java-time/issues/35

Hi! I wasn't quite sure what path to take when implementing the parsing functionality. Please let me know if this is not the right approach.

Thank you for your contribution.
Before I take a look at your PR, could you please confirm that you did not look at the source code of java.time of OpenJDK nor OracleJDK? See https://github.com/scala-js/scala-js-java-time/blob/master/CONTRIBUTING.md

Of Course!
I did not look at the source code of java.time of either OpenJDK or OracleJDK.

@sjrd Would it be possible to get a review please 😄 ?

Ah sorry, I forgot about this. I'll try to fit it sometime this week.

Hey @sjrd Thanks for the review! Let me know if there is anything else I missed!

Ok, thanks for the heads up!

authors: chrisshafer sjrd

repo: scala-js/scala-js-java-time


text:
Porting java.util.Timer

It seems like it should not be too hard to port java.util.Timer and java.util.TimerTask to javalib.
Is this planned? Do you accept contributions?

We certainly accept contributions, as long as they follow the rules :)

Implemented in #2614.

repo: scala-js/scala-js


text:
Code which runs with fastOptJS but crashes with fullOptJS

Minimal reproducing example project:
https://github.com/woost/wust2/tree/fullopt-bug
git clone https://github.com/woost/wust2 -b fullopt-bug --depth=1
cd wust2
./test.sh

Confirmed.
The root cause is that Closure decides to rename our internal property $classData (with we use to distinguish Scala.js objects from JS objects) into b. And then of course it mistakes some JS objects for Scala.js objects, and things go awry.
We should prevent GCC from renaming $classData, although

It will increase the size of -opt.js files
It still leaves us vulnerable to a JS object that has a property named $classData.

A full solution would be to use a symbol instead of $classData. And when symbols are not available, a randomized name with sufficient entropy (e.g., that of a UUID).

Obvious workaround (but which makes -opt.js files much bigger): disable GCC with
scalaJSOptimizerOptions in (Compile, fullOptJS) ~= { _.withUseClosureCompiler(false) }

Fixed in 5918016b88f420c9678888450e2cbe6095f4581d.

authors: fdietze sjrd


text:
Release for Scala 3.0.0-M1

ScalaCheck 1.15.0 has just been deployed to Sonatype, which should allow munit to be released.

I will take a look at making a PR if no one objects.

A backported release of 0.7.15 would be great, too ☺

Thaaat might be harder as I have no idea how to release it locally :sweat_smile:

No need to back port, we can continue publishing new 0.7.x versions.

True, there's no need, but it's a lot more convenient for downstream dependencies. It avoids churn going forward with 3.0.0-M*.

0.7.16 with support for 0.27.0-RC1 and 3.0.0-M1 is now released.

authors: larsrh olafurpg tgodzik

repo: scalameta/munit


text:
Filtering matrix with a bit vector doesn't work

val v = DenseVector(1d, 2d, 3d)
val filteredV = v(v :> 2d) //works fine

val d = DenseMatrix(1d,2d,3d)
val filteredD = d(d(::,0) :>2d,::) //compilation error

The use case here is to filter matrix by some column. Currently, first I use findAll on a particular column and then I filter matrix like this(see below), but the above would be more compact.
val idx = d.filterAll(x => x>2)
d(idx,::)

Ideally I would like to filter matrix by row like this (or something like that):
m.filterByRow(row => ....)

this function implements the functionality described above, but is it consistent with the breeze idioms/syntax patterns?
i think "filter matrix by row" refers to filtering rows from a matrix based on value(s) in a given column; so the function below takes three arguments: the DenseMatrix, a column ID, and a filter function and returns a DenseMatrix whose rows are some subset of the one passed in. Therefore, i named this function filterRows rather than filterByRow
lastly, how should it be made generic? Clearly breeze uses spire, but not extensively (usually just cfor); other DenseMatrix and DenseVector methods are @specialized, but what is the current breeze standard for parameterized types?'
    // spire to make the function generic:
    import spire.implicits._
    import spire.math._
    import spire.algebra._

    def filterRows[A:Numeric](M:breeze.linalg.DenseMatrix[A], colId:Int, f:A => Boolean) = {
        val col = M(::,colId)
        val idx = col.findAll(f)
        M(idx,::).toDenseMatrix
    }

call it like so:
    val m = DenseMatrix((5, 7, 8), (7, 1, 3), (6, 7, 4))

    def f(x:A):Boolean = (x < 6)

    filterRows(m, 1, f)

Hi! I actually just issued a pull request which addresses this functionality (among other things). It allows for consistent slicing operations across Vector, DenseMatrix, and SliceMatrix. If accepted you will be able to use a BitVector in either the rowSlice, colSlice or both.

authors: alexland danielkorzekwa mpetnuch

repo: scalanlp/breeze


text:
Publish 3.1.0 for Scala.js 1.0.0-RC1?

ScalaTest 3.1.0 was published for Scala.js 0.6.x and 1.0.0-M8. AFAICT, it should be possible to publish 3.1.0 as is for Scala.js 1.0.0-RC1. 1.0.0-RC1 should be source compatible with 1.0.0-M8 as far as ScalaTest's use of it is concerned. I believe it would just be a matter of someone with the appropriate rights to run the following script after git checkout release-3.1.0, derived from publish.sh:
sbt clean
export SCALAJS_VERSION=1.0.0-RC1
sbt ++2.11.12 "project scalacticJS" clean publishSigned
sbt ++2.12.10 "project scalacticJS" clean publishSigned
sbt ++2.13.1 "project scalacticJS" clean publishSigned
sbt "project scalactic" sonatypeBundleUpload

sbt clean
export SCALAJS_VERSION=1.0.0-RC1
sbt ++2.11.12 "project scalatestJS" clean publishSigned
sbt ++2.12.10 "project scalatestJS" clean publishSigned
sbt ++2.13.1 "project scalatestJS" clean publishSigned
sbt "project scalatest" sonatypeBundleUpload

sbt clean
export SCALAJS_VERSION=1.0.0-RC1
sbt ++2.11.12 "project scalatestAppJS" clean publishSigned
sbt ++2.12.10 "project scalatestAppJS" clean publishSigned
sbt ++2.13.1 "project scalatestAppJS" clean publishSigned
sbt sonatypeBundleUpload

If it is indeed that simple, could someone do that?
Thank you in advance.

This was done :) See comment at https://github.com/scalatest/scalatest/pull/1730#issuecomment-561683619

repo: scalatest/scalatest


text:
feature: Paragraph.bullet

Hi,Scanny,
Thanks for your feedback to remove the bullet symbol in PPT template mother page setting, but still wonder if it can be set by something like that "paragraph.bullet.type = PP_BULLET_NONE" as a feature.
Le

:+1:

Hi @scanny,
Is there any way I can work around this? I.e. how can I change bullet type and visibility on a paragraph?

You'd need to inspect the underlying XML to understand what elements control that and then manipulate them directly using lxml calls. Search on "python-pptx workaround function" for some examples. Once you get an idea what controls it, the XML Schema documents for this vocabulary will be a help. They're over here: https://github.com/scanny/python-pptx/blob/master/spec/ISO-IEC-29500-4/xsd/wml.xsd

authors: probonopd scanny themiwi zhongle

repo: scanny/python-pptx


text:
Realtime Updates Broken?

I'm not seeing updates when sending messages until I reload the page

After thoroughly testing this with the latest version of apollo-client, I think the issue lies with their package for updateQuery. I've pushed the change for that package back down to the latest working version. Until we work this out with the Apollo team, please re-clone this repo and use an older version of Apollo.

Any news here? I'am trying to implement the subscriptions.
I'am using the official apollo-client subscriptions documentation, but after the setup the chrome dev-tools are just logging:
WebSocket connection to 'wss://eu-west-1.api.scaphold.io/graphql/xxx' failed: WebSocket is closed before the connection is established.
app.js:73

Since the apollo libraries changed so much that the scaphold examples / documentation are not up to date anymore its quit hard to find a solution for this :(

This example with not run correctly. I just followed the tutorial, but get errors in the console:
Unhandled (in react-apollo) Error: Network error: Network request failed with status 401 - ""
    at new ApolloError (eval at <anonymous> (http://127.0.0.1:8888/bundle.js:4304:2), <anonymous>:1804:28)

 No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://127.0.0.1:8888' is therefore not allowed access. The response had HTTP status code 404.
VM8539:541 There was an error fetching the SSO data. This could simply mean that there was a problem with the network. But, if a "Origin" error has been logged before this warning, please add "http://127.0.0.1:8888" to the "Allowed Origins (CORS)" list in the Auth0 dashboard: https://manage.auth0.com/#/applications/pDRoqCoHSiMDoVkGB2fEvttwmcEqIL-5/settings

Having the same websocket error as @michaelzoidl

authors: BrianSandholdt immanuelrosal michaelzoidl timcamber vning93


text:
do not relay only on ctypes.util.find_library

there are situations where find library does not work, there are also people that do not want to install (make install) to standard paths. Provide a way how to specify location of so/dll

fixed in https://github.com/scgbckbone/python-secp256k1/pull/5/f


text:
Register 0.2.1

@JuliaRegistrator register
Improvements to documentation, added functions, anti_chain_cover renamed antichain_cover.

Registration pull request created: JuliaRegistries/General/112896
Tip: Release Notes
Did you know you can add release notes too? Just add markdown formatted text underneath the comment after the text
"Release notes:" and it will be added to the registry PR, and if TagBot is installed it will also be added to the
release that TagBot creates. i.e.
@JuliaRegistrator register

Release notes:

## Breaking changes

- blah

To add them here just re-invoke and the PR will be updated.
Tagging
After the above pull request is merged, it is recommended that a tag is created on this repository for the registered package version.
This will be done automatically if the Julia TagBot GitHub Action is installed, or can be done manually through the github interface, or via:
git tag -a v0.2.1 -m "<description of version>" 62e44c97bfe6ea1e0d1fb1779c00b822c972d385
git push origin v0.2.1

@JuliaRegistrator register

Registration pull request updated: JuliaRegistries/General/112896
Tip: Release Notes
Did you know you can add release notes too? Just add markdown formatted text underneath the comment after the text
"Release notes:" and it will be added to the registry PR, and if TagBot is installed it will also be added to the
release that TagBot creates. i.e.
@JuliaRegistrator register

Release notes:

## Breaking changes

- blah

To add them here just re-invoke and the PR will be updated.
Tagging
After the above pull request is merged, it is recommended that a tag is created on this repository for the registered package version.
This will be done automatically if the Julia TagBot GitHub Action is installed, or can be done manually through the github interface, or via:
git tag -a v0.2.1 -m "<description of version>" bb71eb919724acaf7e6039b9c95aa8fe6f9360f1
git push origin v0.2.1

authors: JuliaRegistrator scheinerman


text:
add page for timer

I think it would be great if we can view the timer in a page, (sync with icon)

A similar request exists in https://github.com/schmich/marinara/issues/176 with additional details. Consider merging with that one?

authors: eeshanshrimali suwardhana

repo: schmich/marinara


text:
Refs needing persistence

This is really minor/irrelevant since this mod isn't esm-flagged, but I scanned the most recent build with the Persistify script (https://www.nexusmods.com/skyrimspecialedition/mods/76750) and it detected two records that should be Persistent but aren't:
WFieldCOImperialHaafingar "Legate Adventus Caesennius" [NPC_:000844B1] - ([ACHR:0842B69A])
CWFieldCOSonsEastmarch "Yrsarald Thrice-Pierced" [NPC_:00084551] - ([ACHR:0842B69B])
(the ACHR ones are the ones that need the Persistent flag)

Thank you! Fixed in 1.0.17

authors: DarthVitrial schofida

repo: schofida/CWORR


text:
🛑 findabooktoread.com is down

In ca83721, findabooktoread.com (https://findabooktoread.com/) was down:

HTTP code: 502
Response time: 121 ms

Resolved: findabooktoread.com is back up in 35ccb01 after 7 minutes.

repo: schollz/upptime


text:
🛑 teoperator.com is down

In f445f17, teoperator.com (https://teoperator.com/) was down:

HTTP code: 0
Response time: 0 ms

Resolved: teoperator.com is back up in d464030 after 7 minutes.


text:
🛑 findabooktoread.com is down

In 5129a71, findabooktoread.com (https://findabooktoread.com/) was down:

HTTP code: 502
Response time: 368 ms

Resolved: findabooktoread.com is back up in fef37e5.


text:
Decide how we'll implement the article feed

In the spec there's a feed endpoint made up of articles written by people you follow.
Problem: The people you follow is not necessarily a small number.
I see two ways to go here:

We assume there is an actual limit (say, 500) to the people you can follow, and we use the 500 ids in a SQL query.
We materialize a feed per user via listeners. New article published? Let's push it into the feeds of all users. I heard this is how facebook does it.
We take a hybrid / heuristic approach. If a user follows < LIMIT people, we calculate it. Otherwise we materialize it.

Since the purpose of this example is to show how we would do it in a real scenario, I would actually consider just (2) or (3), but let me know what you think!

I will go with (2). I do not see the benefits of (3) over (2), and it is a more complex solution.

Fair enough, go ahead ;)

authors: hecrj larribas


text:
decompress doesnt return value if input is bigger than something arbitrair

Hello,
I noticed when decompressing it is kinda random if the data will be returned or the app will quit without any message.
when I run this code which is a modification on the readme code it the output is kinda odd, its incomplete besides that there is clearly data missing.
const lzo = require('lzo')

function log( ...args ){
	console.log( args.reduce( ( m, arg ) => {
		arg = arg.toString().slice( 0, 10 )
		m += ( arg + ' '.repeat( 10 - arg.length ))
		return m
	}, '' ) )
}

console.log( 'o: Original data\nc: Compressed data\ndc:Decompressed data' )
log( 'o length', 'c length', 'dc length', 'equal size', 'o slice matches dc' )

function test( len ){
	const str = '0123456789'.repeat( len )
	const compressed = lzo.compress(str)
	const decompressed = lzo.decompress(compressed)
	log( str.length, compressed.length, decompressed.length, str == decompressed, str.slice(0,decompressed.length) == decompressed )
}

for( let i = 0; i < 10; i++ ){
	test( i )
}
for( let i = 10; i <= 100; i += 10 ){
	test( i )
}

output:
>node testDecompress.js
o: Original data
c: Compressed data
dc:Decompressed data
o length  c length  dc length equal sizeo slice ma
0         3         0         true      true
10        14        10        true      true
20        24        20        true      true
30        34        30        true      true
40        36        40        true      true
50        39        50        true      true
60        33        60        true      true
70        35        70        true      true
80        37        80        true      true
90        40        90        true      true
100       33        99        false     true
200       37        111       false     true
300       33        99        false     true
400       38        114       false     true
>

is the data length restricted to 99 for decompression?
what causes the unexpected exit, is the code internally going async?
running this app multiple times shows different output every time, sometimes it gets to logging 100 sometimes it finishes, but most of the time it exits somewhere in between.

const lzo = require('lzo');

function test(len) {
    let buf = Buffer.allocUnsafe(len),
        comp = lzo.compress(buf),
        decomp = lzo.decompress(comp);

    console.log('length:', buf.length, '-- cl:', comp.length, '-- dl:', decomp.length, '-- equal:', buf.compare(decomp) === 0);
}

let start = 0, // Even 40 000 works fine as long as it's only run once
    times = 10;

for(let i=start; i<start + times; i++)
    test(i);

I quickly put this thing together to simplify everything a little bit and noticed that it only start failing once the overall  amount of data exceeds a certain limit. It doesn't matter whether it is reached by using a high starting point and only running it once or by using a low starting point and running it a lot of times.

authors: crostine schroffl

repo: schroffl/node-lzo


text:
Raw HTML injection does not for client only app

Description
I am not seeing a very clear and obvious way to directly inject HTML into the DOM. Basically I just want to take a string and have it be placed in the DOM at a specific location, without any sort of manipulation from jaspr.
My expectation is that this would be the way to do it:
text('<img src="https://ui-avatars.com/api/?name=jaspr">',rawHtml: true)

However, when trying to use this on simple or complicating raw HTML strings I keep seeing all sorts of side effects. The rawHtml flag is doing something odd to the resulting HTML and interfering with other elements.
Steps To Reproduce
See the repo below, on the raw-html branch for a complete working example and a README with other context:
https://github.com/walsha2/jaspr-issues/tree/raw-html
Feedback
Injecting raw HTML should have first class support. Sometimes there are chucks of raw HTML code that we just want to copy (e.g. an svg with many path components) and insert into the DOM without needing to fist manually convert in the jaspr native components, which can be tedious. I had to do this for an svg and it was not fun.
Using text('...',rawHtml: true) seems a bit like a second class feature? I know it sounds trivial, but something like raw('...') seems to make more sense. Maybe this even bypasses the entire Component processing to ensure that there are no unintended side effects to the raw code. Im sure that is what the intent of rawHtml flag is doing, but it seems like that might not be the case as evidenced by this bug.
The docs for text state "Utility method to create a text component when using jaspr html methods" and that does not sounds like what I want to do necessarily. It could just be a matter of semantics, but this isn't a "text component", it is a raw DOM element and I do not want it to use any "jaspr html methods".

Update - as with seemingly all of my recent issues, this problem is isolated to client only apps.

Thanks for this issue.
You are right that right now rawHtml is not well working on the client, especially when used along sibling components.
I like the proposal of using a separate raw() method and removing the rawHtml flag from the text component.

repo: schultek/jaspr


text:
Make handshake timeout configurable

Change to allow configuring handshake timeout to be a value other than 5 seconds.

Note that default value of ws.timeout is also 5 seconds.

👍 Seems reasonable,  thanks for the PR

authors: mariusdw schwartzmx

repo: schwartzmx/gremtune


text:
computing election feature causes name error

error :
File "mapof-elections\src\mapof\elections\objects\ElectionExperiment.py", line 635, in compute_feature     if feature_id in MAIN_GLOBAL_FEATUERS or feature_id in ELECTION_GLOBAL_FEATURES:                      ^^^^^^^^^^^^^^^^^^^^ NameError: name 'MAIN_GLOBAL_FEATUERS' is not defined

works for my specific case by just removing the whole if from said if block
i don't know the code-base good enough to know if that is a good long term solution

Thanks. I fixed this by adding appropriate imports.

authors: itayzimet szufix

repo: science-for-democracy/mapof-elections


text:
Fix use of auditwheel pinning wheel to 0.31.1

See https://github.com/pypa/auditwheel/issues/102
See https://circleci.com/gh/scikit-build/ninja-python-distributions/344
Thanks @kjerstadius for investigating the issue. See #18

Closing. Instead PR #18 has been updated to include corresponding changes.

repo: scikit-build/ninja-python-distributions


text:
Reading DAOD_PHYSLITE files; issue with ak.fields on the returned array.

OS; MacOS Monterey 12.2.1 (I can also try a linux box if that's useful)
python; 3.10.4 (using ipython 8.2.0)
awkward; 1.8.0
uproot; 4.2.2
So I was following the notes in https://github.com/scikit-hep/uproot4/issues/123 to read a DAOD_PHYSLITE file, in particular, I'm reading the first file posted DAOD_PHYSLITE.art.pool.root.
The reading goes fine and I can get values, only when I try to read the fields of the returned array I get an error. Is that something that would normally work?
Minimal broken example;
import uproot
import awkward as ak
f = uproot.open("DAOD_PHYSLITE.art.pool.root")
t = f["CollectionTree"]
arrays = t["AnalysisElectronsAuxDyn.trackParticleLinks"].array(library="np")
ak.fields(arrays)

Gives me the error
---------------------------------------------------------------------------
ValueError                                Traceback (most recent call last)
File ~/CTU/reading_DAOD_PHYSLITE/errors.py:6, in <module>
      4 t = f["CollectionTree"]
      5 arrays = t["AnalysisElectronsAuxDyn.trackParticleLinks"].array(library="np")
----> 6 ak.fields(arrays)

File /opt/homebrew/Caskroom/miniconda/base/envs/latest_uproot/lib/python3.10/site-packages/awkward/operations/describe.py:263, in fields(array)
    250 def fields(array):
    251     """
    252     Extracts record fields or tuple slot numbers from `array` (many types
    253     supported, including all Awkward Arrays and Records).
   (...)
    261     list.
    262     """
--> 263     layout = ak.operations.convert.to_layout(
    264         array, allow_record=True, allow_other=False
    265     )
    266     return layout.keys()

File /opt/homebrew/Caskroom/miniconda/base/envs/latest_uproot/lib/python3.10/site-packages/awkward/operations/convert.py:1902, in to_layout(array, allow_record, allow_other, numpytype)
   1900 elif isinstance(array, (np.ndarray, numpy.ma.MaskedArray)):
   1901     if not issubclass(array.dtype.type, numpytype):
-> 1902         raise ValueError(
   1903             f"NumPy {array.dtype!r} not allowed"
   1904             + ak._util.exception_suffix(__file__)
   1905         )
   1906     return from_numpy(array, regulararray=True, recordarray=True, highlevel=False)
   1908 elif (
   1909     type(array).__module__.startswith("cupy.") and type(array).__name__ == "ndarray"
   1910 ):

ValueError: NumPy dtype('O') not allowed

(https://github.com/scikit-hep/awkward-1.0/blob/1.8.0/src/awkward/operations/convert.py#L1904)

It's not urgent or anything, but I'd like to promote uproot for reading DAOD_PHYSLITE files in my group, so it would be neat if that worked. If it's really a bug, and you think it reasonable, I'm happy to have a go at fixing it tonight?

Ah, never mind, I'm trying to call ak.fields on a numpy array.....


text:
ImportError: cannot import name MaskedArray

I got scikit-optimize from your pypi release here, where it says I need scikit-learn >= 0.18. "I'm in luck." thought I, for 0.18 I have. But trying to import skopt I get an error that MaskedArray can not be imported from sklearn.utils.fixes, and trying to import that class from there myself also yields an error. Does scikit-optimize actually have a dependency on a later version of sklearn?

Hi @pavelkomarov
MaskedArray is present in both 0.18 and 0.19 releases of sklearn.utils.fixes:
https://github.com/scikit-learn/scikit-learn/blob/0.18.X/sklearn/utils/fixes.py
https://github.com/scikit-learn/scikit-learn/blob/0.19.X/sklearn/utils/fixes.py
I also cannot reproduce your import error on my system. Are you sure you are on the latest sklearn?

I am sure I have sklearn version 0.18, and I am sure from sklearn.utils.fixes import MaskedArray returns an ImportError. I am on numpy 1.11.1. I will try updating it and see what happens. There is that if np_version < (1, 12, 0): class MaskedArray(np.ma.MaskedArray): definition that makes me think MaskedArray might be unnecessary with an updated version of numpy.

Agreed, that part looks suspicious. Let me know how it goes.

Nope, that didn't fix it.

I went deep in to my packages and found that fixes.py actually doesn't have a MaskedArray in 18.0, at least not in the version someone installed here. I will get someone with permissions to edit the source and try to get the latest version of sklearn approved for my project.

With sklearn 0.18.2:
>>> import sklearn
>>> sklearn.__version__
'0.18.2'
>>> from sklearn.utils.fixes import MaskedArray

Yeah, it exists in later versions. I'm having to get the software safety people to review 19.1 so we can just update system-wide.

@pavelkomarov would you like to make a PR to update setup.py to require >=0.18.2?

I suppose I could. I'd love to be a contributor.

I am using Scikit-Learn version 0.23.0 with scikit-opt version 0.7.4. When calling for BayesSearchCV I do get the import error mentioned in the issue title:
ImportError: cannot import name 'MaskedArray'

Yep, same here. It seems sklearn moved MaskedArray once again.

Same Problem here with BayesSearchCV...

Can confirm.  The recent sklearn 0.23 update broke the MaskedArray from sklearn.utils.fixes

This currently breaks all the tests in Adaptive (see this CI report.)

scikit-learn=0.23.0 & scikit-optimize=0.7.4 will raise error ImportError: cannot import name 'MaskedArray'
upgrade to scikit-learn=0.23.1 will resolve it. However, I have another error caused by some other reasons with scikit-optimize: TypeError: object.__init__() takes no parameters when I use BayesSearchCV on scikit-survival CoxPH.

Just want to mention here, that this error still exists with sklearn version 1.0 and skopt version 0.8.1
So it would be necessary install sktop development version 0.9.dev0

@janezlapajne Just install the development version 0.9.dev0:
git clone https://github.com/scikit-optimize/scikit-optimize.git
cd scikit-optimize
pip install -e.

forcing  pip3 install scikit-learn==0.24 numpy==1.19.1 chess-tuning-tools is a work-around.

authors: basnijholt betatim cpoptic epx-dan iaroslav-ai konsti-papa mirca pavelkomarov pgg1610 rene-rex timonmerk tryingsomestuff

repo: scikit-optimize/scikit-optimize


text:
Thread safety RectBivariateSpline

The RectBivariateSpline function seems to not work properly when running in parallel threads. The result of the interpolation call returns different values and sometimes nan.
Tested on Windows 10,
When testing on a different machine with Linux, all worked
Reproducing code example:

import scipy.interpolate
import threading
import numpy as np

# this expample tries use the RectBivariateSpline function in parallel threads
# outputput is generated when the interpolated data in the thread does not
# align with the previously calculatet interpolated data

def f(thread_data, ref_datai):
    # create the interpolation object interpolating thread_data
    thread_finterpol = scipy.interpolate.RectBivariateSpline(
        np.arange(thread_data.shape[0]),
        np.arange(thread_data.shape[1]),
        thread_data
        )

    # calculate coordinates on which to interpolate
    thread_newcoords = np.asarray([np.linspace(20,36), np.linspace(20,38)])
    for i in range(100):
        # create the interpolated data
        thread_datai = thread_finterpol(thread_newcoords[0], thread_newcoords[1])

        # compare interpolated data to reference data
        diff = ref_datai-thread_datai

        if not np.min(diff)==0 or not np.max(diff) == 0:
            # prints the diffrerence to the reference
            # this conditions are only reached when Nthreads > 1
            print(i, np.min(diff), np.max(diff))
#            raise Exception("Interpolation has failed")

# create data to interpolate
data = np.random.random((100,100))
# interpolation function
finterpol = scipy.interpolate.RectBivariateSpline(
        np.arange(data.shape[0]),
        np.arange(data.shape[1]),
        data
        )

newcoords1 = np.asarray([np.linspace(20,36), np.linspace(20,38)])
# reference interpolation
datai = finterpol(newcoords1[0], newcoords1[1])

Nthreads = 1 # Number of threads created
tlist = []
for j in range(Nthreads):
    t = threading.Thread(target = f,
                         args = (data.copy(), # copy the data so it is definitely thread safe
                                 datai.copy())

                         )
    t.start()
    tlist.append(t)

Error message:

Scipy/Numpy/Python version information:
tested with versions
1.3.1 1.16.5 sys.version_info(major=3, minor=7, micro=4, releaselevel='final', serial=0)

and
1.6.2 1.19.2 sys.version_info(major=3, minor=7, micro=4, releaselevel='final', serial=0)

Likely similar to https://github.com/scipy/scipy/issues/11828

very strange.
the problem seems to be during initialization. As a workaround, i am using the following object to make the call "thread-safe":
class RectBivariateSpline(scipy.interpolate.RectBivariateSpline):
    _splineLock = threading.Lock()

    def __init__(self, *args, **kwargs):
        self._splineLock.acquire()
        try:
            return super().__init__(*args, **kwargs)
        finally:
            self._splineLock.release()

repo: scipy/scipy


text:
ENH: Accept kwargs in cramervonmises

Is your feature request related to a problem? Please describe.
The cramervonmises test does not support kwargs on top of args for distributions called by name. It would be helpful for testing distributions with alternative parametrizations (like gengamma):
# Testing GenGamma(a, d, p) as defined in https://en.wikipedia.org/wiki/Generalized_gamma_distribution
test = cramervonmises(samples, 'gengamma', args=(d/p, p), kargs={scale=a})

Describe the solution you'd like.
The most obvious one would be to forward the kwargs to the cdf call in cramervonmises:
https://github.com/scipy/scipy/blob/c1ed5ece8ffbf05356a22a8106affcd11bd3aee0/scipy/stats/_hypotests.py#L589
Would become:
cdfvals = cdf(vals, *args, **kwargs)

Describe alternatives you've considered.
You can get around by forwarding args = (*args, loc, scale) but that only works because of the implementation details in rv.cdf:
https://github.com/scipy/scipy/blob/9d74b29239d05f6ec63e4c16cd8a49d0fa58e7c2/scipy/stats/_distn_infrastructure.py#L2061
Additional context (e.g. screenshots, GIFs)
No response

Thank you for reporting @FredericWantiez. It's a bit unfortunate we went with this interface. As it is it seems legitimate. Personally I would instead advocate to only allow passing a callable (so you would create beforehand the correct distribution.) There is little to no need to do this within the function. Defining fully a distribution by passing all arguments vs passing a distribution.

It doesn't look like that is SciPy's version of gengamma you're referring to, right? SciPy's doesn't offer an alternative parametrization, AFAICT.
cramervonmises probably went with that interface to follow ks_1samp, which is quite old. But I think both allow the user to pass the CDF of a frozen distribution, i.e. one that accepts only x and no additional parameters. Does that not work for you, @FredericWantiez?

authors: FredericWantiez mdhaber tupui


text:
BLD: build warnings from quadpack

Describe your issue.
The recent Quadpack rewrite in C results in a few probably harmless build warnings. Opening the issue for visbility mostly. CC @ilayn
Reproducing Code Example
[1074/1277] Compiling C object scipy/integrate/_quadpack.cpython-312-x86_64-linux-gnu.so.p/__quadpack.c.o
../scipy/integrate/__quadpack.c: In function 'dqagie':
../scipy/integrate/__quadpack.c:540:16: warning: 'erlarg' may be used uninitialized [-Wmaybe-uninitialized]
  540 |         erlarg = erlarg - erlast;
      |         ~~~~~~~^~~~~~~~~~~~~~~~~
../scipy/integrate/__quadpack.c:406:34: note: 'erlarg' was declared here
  406 |     double defab1, defab2, dres, erlarg, erlast, errbnd, errmax, error1, error2;
      |                                  ^~~~~~
../scipy/integrate/__quadpack.c:551:27: warning: 'ertest' may be used uninitialized [-Wmaybe-uninitialized]
  551 |         if ((ierror == 3) || (erlarg <= ertest)) { goto LINE60; }
      |             ~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~
../scipy/integrate/__quadpack.c:407:29: note: 'ertest' was declared here
  407 |     double error12, errsum, ertest, resabs, reseps, small;
      |                             ^~~~~~
../scipy/integrate/__quadpack.c: In function 'dqagse':
../scipy/integrate/__quadpack.c:1529:27: warning: 'ertest' may be used uninitialized [-Wmaybe-uninitialized]
 1529 |         if ((ierror == 3) || (erlarg <= ertest)) { goto LINE60; }
      |             ~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~
../scipy/integrate/__quadpack.c:1386:12: note: 'ertest' was declared here
 1386 |     double ertest, small, jupbnd, correc, resabs, reseps, abseps;
      |            ^~~~~~

Error message
N/A

SciPy/NumPy/Python version and system information
1.15.0.dev0+git20241008.548350a 2.1.2 sys.version_info(major=3, minor=12, micro=7, releaselevel='final', serial=0)
Build Dependencies:
  blas:
    detection method: pkgconfig
    found: true
    include directory: /home/tyrion/miniforge3/envs/scipy-dev/include
    lib directory: /home/tyrion/miniforge3/envs/scipy-dev/lib
    name: openblas
    openblas configuration: USE_64BITINT=0 DYNAMIC_ARCH=1 DYNAMIC_OLDER= NO_CBLAS=
      NO_LAPACK=0 NO_LAPACKE= NO_AFFINITY=1 USE_OPENMP=0 PRESCOTT MAX_THREADS=128
    pc file directory: /home/tyrion/miniforge3/envs/scipy-dev/lib/pkgconfig
    version: 0.3.27
  lapack:
    detection method: pkgconfig
    found: true
    include directory: /home/tyrion/miniforge3/envs/scipy-dev/include
    lib directory: /home/tyrion/miniforge3/envs/scipy-dev/lib
    name: openblas
    openblas configuration: USE_64BITINT=0 DYNAMIC_ARCH=1 DYNAMIC_OLDER= NO_CBLAS=
      NO_LAPACK=0 NO_LAPACKE= NO_AFFINITY=1 USE_OPENMP=0 PRESCOTT MAX_THREADS=128
    pc file directory: /home/tyrion/miniforge3/envs/scipy-dev/lib/pkgconfig
    version: 0.3.27
  pybind11:
    detection method: pkgconfig
    include directory: /home/tyrion/miniforge3/envs/scipy-dev/include
    name: pybind11
    version: 2.13.6
Compilers:
  c:
    args: -march=nocona, -mtune=haswell, -ftree-vectorize, -fPIC, -fstack-protector-strong,
      -fno-plt, -O2, -ffunction-sections, -pipe, -isystem, /home/tyrion/miniforge3/envs/scipy-dev/include,
      -DNDEBUG, -D_FORTIFY_SOURCE=2, -O2, -isystem, /home/tyrion/miniforge3/envs/scipy-dev/include
    commands: /home/tyrion/miniforge3/envs/scipy-dev/bin/x86_64-conda-linux-gnu-cc
    linker: ld.bfd
    linker args: -Wl,-O2, -Wl,--sort-common, -Wl,--as-needed, -Wl,-z,relro, -Wl,-z,now,
      -Wl,--disable-new-dtags, -Wl,--gc-sections, -Wl,--allow-shlib-undefined, -Wl,-rpath,/home/tyrion/miniforge3/envs/scipy-dev/lib,
      -Wl,-rpath-link,/home/tyrion/miniforge3/envs/scipy-dev/lib, -L/home/tyrion/miniforge3/envs/scipy-dev/lib,
      -march=nocona, -mtune=haswell, -ftree-vectorize, -fPIC, -fstack-protector-strong,
      -fno-plt, -O2, -ffunction-sections, -pipe, -isystem, /home/tyrion/miniforge3/envs/scipy-dev/include,
      -DNDEBUG, -D_FORTIFY_SOURCE=2, -O2, -isystem, /home/tyrion/miniforge3/envs/scipy-dev/include
    name: gcc
    version: 13.3.0
  c++:
    args: -fvisibility-inlines-hidden, -fmessage-length=0, -march=nocona, -mtune=haswell,
      -ftree-vectorize, -fPIC, -fstack-protector-strong, -fno-plt, -O2, -ffunction-sections,
      -pipe, -isystem, /home/tyrion/miniforge3/envs/scipy-dev/include, -DNDEBUG, -D_FORTIFY_SOURCE=2,
      -O2, -isystem, /home/tyrion/miniforge3/envs/scipy-dev/include
    commands: /home/tyrion/miniforge3/envs/scipy-dev/bin/x86_64-conda-linux-gnu-c++
    linker: ld.bfd
    linker args: -Wl,-O2, -Wl,--sort-common, -Wl,--as-needed, -Wl,-z,relro, -Wl,-z,now,
      -Wl,--disable-new-dtags, -Wl,--gc-sections, -Wl,--allow-shlib-undefined, -Wl,-rpath,/home/tyrion/miniforge3/envs/scipy-dev/lib,
      -Wl,-rpath-link,/home/tyrion/miniforge3/envs/scipy-dev/lib, -L/home/tyrion/miniforge3/envs/scipy-dev/lib,
      -fvisibility-inlines-hidden, -fmessage-length=0, -march=nocona, -mtune=haswell,
      -ftree-vectorize, -fPIC, -fstack-protector-strong, -fno-plt, -O2, -ffunction-sections,
      -pipe, -isystem, /home/tyrion/miniforge3/envs/scipy-dev/include, -DNDEBUG, -D_FORTIFY_SOURCE=2,
      -O2, -isystem, /home/tyrion/miniforge3/envs/scipy-dev/include
    name: gcc
    version: 13.3.0
  cython:
    commands: cython
    linker: cython
    name: cython
    version: 3.0.11
  fortran:
    args: -march=nocona, -mtune=haswell, -ftree-vectorize, -fPIC, -fstack-protector-strong,
      -fno-plt, -O2, -ffunction-sections, -pipe, -isystem, /home/tyrion/miniforge3/envs/scipy-dev/include
    commands: /home/tyrion/miniforge3/envs/scipy-dev/bin/x86_64-conda-linux-gnu-gfortran
    linker: ld.bfd
    linker args: -Wl,-O2, -Wl,--sort-common, -Wl,--as-needed, -Wl,-z,relro, -Wl,-z,now,
      -Wl,--disable-new-dtags, -Wl,--gc-sections, -Wl,--allow-shlib-undefined, -Wl,-rpath,/home/tyrion/miniforge3/envs/scipy-dev/lib,
      -Wl,-rpath-link,/home/tyrion/miniforge3/envs/scipy-dev/lib, -L/home/tyrion/miniforge3/envs/scipy-dev/lib,
      -march=nocona, -mtune=haswell, -ftree-vectorize, -fPIC, -fstack-protector-strong,
      -fno-plt, -O2, -ffunction-sections, -pipe, -isystem, /home/tyrion/miniforge3/envs/scipy-dev/include
    name: gcc
    version: 13.3.0
  pythran:
    include directory: ../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/pythran
    version: 0.16.1
Machine Information:
  build:
    cpu: x86_64
    endian: little
    family: x86_64
    system: linux
  cross-compiled: false
  host:
    cpu: x86_64
    endian: little
    family: x86_64
    system: linux
Python Information:
  path: /home/tyrion/miniforge3/envs/scipy-dev/bin/python3.12
  version: '3.12'

I used a slightly newer gcc (14.2.0) on Linux and didn't reproduce--can I ask your incantation for building?

this I can reproduce. Probably some initialization needed to silence the warnings. They are initialized safely in the branch but compiler does not resolve it.

authors: dschmitz89 ilayn tylerjereddy


text:
does scipy.interpolate.UnivariateSpline.derivative(n=2)(x) mean the 2-order derivative at x?

I am using scipy 1.1.0 and numpy 1.12.1 which are supplied by anaconda python latest.
As we know, dsin(x)/dx = cos(x) and d2sin(x)/dx2 = -sin(x)
In the following example, I first interpolate discreted sine curve and get spline s1. The figure proves that s1 is nearly the cosine curve.
As doc says, s1.derivative(n=2) returns a new spline representing the 2-order derivative of this spline, so I think s1.derivative(n=2)(x) should be -sin(x). But the result shows that s1.derivative(n=2)(x) is almost a straight line. Why? Did I misunderstand the document?
import scipy.interpolate as inter
import numpy as np
import pylab as plt

import scipy

print(scipy.__version__)
print(np.__version__)

x = np.arange(0, 2*np.pi, 0.1)
y = np.sin(x)

s1 = inter.UnivariateSpline (x, y)

plt.plot (x, y, 'bo', label='Data')

plt.plot (x, s1(x), 'k--', label='Spline, s=default')

plt.minorticks_on()

plt.plot(x, s1.derivative(1)(x), 'd', label='df/ds')
plt.plot(x, s1.derivative(n=2)(x), 'p', label='d2f/ds2')

plt.legend()
plt.xlabel('x')
plt.ylabel('y')
plt.show()

thanks

UnivariateSpline constructs, essentially, a piecewise cubic polynomial. The second derivative of a cubic parabola is indeed a linear function, so it's all consistent.

@retsyo, your code will work as you expected if you tell UnivarateSpline to use no smoothing.  That is, create s1 with the option s=0:
s1 = inter.UnivariateSpline (x, y, s=0)

Here's the plot that is generated after making that change:

authors: WarrenWeckesser ev-br retsyo


text:
BUG: Avoid exponnorm producing nan for small K values.

Fixes #10003 with the fix suggested by @ev-br.

All green, so in it goes. Thanks @peterbell10, keep them coming!


text:
DOC: Remove the "Basic functions" section from the SciPy tutorial.

Reference issue
To fix #12413
What does this implement/fix?
Removed the "Basic functions" section from the SciPy tutorial.
The "Basic Functions" section of the SciPy tutorial is actually a small NumPy tutorial. NumPy has great documentation, including tutorials, so I think we can simply remove this entire section.

Perhaps instead of completely removing this section, it should be demoted to a short paragraph in the introduction stating a basic understanding of NumPy is required and links to their tutorials?

Perhaps instead of completely removing this section, it should be demoted to a short paragraph in the introduction stating a > basic understanding of NumPy is required and links to their tutorials?
I think that is good idea.
What do you think? @WarrenWeckesser

I updated code using @peterbell10 's idea.

I'd say that linking to NumPy and how to find docs is already covered in the Introduction section: http://scipy.github.io/devdocs/tutorial/general.html. I don't quite see why we would want to keep a Basic functions section in the top-level overview of tutorials for a redundant couple of lines? Removing this entry would be good:

Thank you for reviewing. I didn't know there is a doc link in the introduction. I agree. I deleted it again. PTAL.

I think removing these files and tweaking doc/source/tutorial/general.rst was what @peterbell10 meant. That file could use a more extensive makeover, so let's not block merging this PR on it.
In it goes, thanks @AtsushiSakai.

authors: AtsushiSakai peterbell10 rgommers


text:
Uploading by label returns empty result

When sending a POST to /api/upload/label which creates a new project/session/acquisition hierarchy, the response body is an empty list even though objects were created

As @coltonlw talked about offline, the upload endpoints only return a list of file objects created, so it is behaving "as designed". It would be nice if endpoints that create/find hierarchy (label/uid/packfile upload) returned at least the _id fields of the hierarchy they found/created.

authors: coltonlw nagem

repo: scitran/core


text:
Add script to generate sources into generated branch

Created as a result of the discussion in https://github.com/sclorg/postgresql-container/pull/268

@praiskup @omron93 ptal

Made some more minor changes. Ready for review now.

Thanks, merging

repo: sclorg/container-common-scripts


text:
GCI- New UI for Soundcom app

Removed Merge Conflicts.

repo: scorelab/soundcom