-
-
Notifications
You must be signed in to change notification settings - Fork 3.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update Comparative Population Studies #2434
Conversation
Remove reference to nonexistent term. (Perhaps the validator could check for these?)
Awesome! You've created a pull request to the Citation Styles Language styles repository. We'll get in touch soon (usually within a day or two). In the meantime, our automated test system will go ahead and run some checks on your pull request. In a few minutes you'll be notified of the test results. If you haven't done so yet, please make sure your style validates and follows all our other Style Requirements. To update the current pull request, visit the "Files changed" tab above, and click on the pencil icon (see below) in the top-right corner of your style to start editing. If you need assistance at any point, please leave a comment and we'll get back to you (feel free to write in Dutch, English, French, German, Portuguese, or Spanish). |
😃 Your submission passed all our automated tests. |
Well, it's actually a valid term according to the schema (see https://github.com/citation-style-language/schema/blob/v1.0.1/csl-terms.rnc#L130), but it looks like we may have missed listing this type of terms in the specification. |
(I also think the CSL locale files contain a subset of all allowed terms) |
Hmm, when I try to insert a report with the style as first submitted in Word, I get a "trmtext not found" error. Perhaps it is a bug with citeproc-js then? In any event, the term line should be removed (there should be no label for number; compare the parallel code on line 196). |
Well, it looks more like a helpful warning that you're trying to use a term for which no translations are available in either the locale files or the style itself. |
"Helpful warning" -- it stops the document from updating at all and prevents the insertion of the citation. |
If it's that bad, it might be worthwhile reporting the issue to @fbennett. Frank, citeproc-js apparently really doesn't like cases where it can't find a translation for a term. See above. Could it be changed to fail more gently? |
If the style is missing a term, it does seem like it would be better for the error to be called to the user's attention somehow. The processor can throw a more meaningful error (I'll set that up), but making that easily discoverable would be a job for the calling application. About all the processor could do to surface it would be to throw an ugly citation, which could have bad consequences for authors. Is it possible to catch these in validation? |
It's tricky, since we currently don't require that each term (or form) is defined in the locale files. I would just default to "" for undefined terms. |
Could it default to NULL (or similar) so that affixes and group delimiters are not printed around the "" ? |
Yeah, that probably would be better. (I'm not totally sure why this bug occurs, though, since we previously already deleted the "author" terms, and we never hear any problems about those: citation-style-language/locales@3b6a1b5) |
If the absent term returns empty, affixes and delimiters should go away. So
failing silently without error would be okay?
…On Jan 18, 2017 00:57, "Rintze M. Zelle" ***@***.***> wrote:
Yeah, that probably would be better.
(I'm not totally sure why this bug occurs, though, since we previously
already deleted the "author" terms, and we never hear any problems about
those: ***@***.***
<citation-style-language/locales@3b6a1b5>
)
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#2434 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AAEmSprp0-oCiyXggK1eNralSFL_LPBaks5rTOUDgaJpZM4LkvHw>
.
|
I think that would be preferable, yes. @adam3smith? |
yes, I'd rather have this failing silently |
I've fixed it for cs:text w/term attribute, and pushed new versions of the Propachi plugins. I think cs:label is already tolerant, but if there a more snags, give a shout. @rmzelle @adam3smith @bwiernik |
@bwiernik, would you mind testing this with the original style? |
Also, thanks Frank! |
cs:text with term="number" still fails with the same error. cs:label with term="number" returns no error. |
Ouch, teething pains. I did test that, something must have gone awry. Will
go through it more carefully tomorrow.
…On Jan 19, 2017 19:39, "bwiernik" ***@***.***> wrote:
cs:text with term="number" still fails with the same error. cs:label with
term="number" returns no error.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#2434 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AAEmStwj0uffD55unt-ltlzaKsc9PMLlks5rTz1ugaJpZM4LkvHw>
.
|
I've gotten it to load without error in Zotero 5.0 beta standalone, and the processor replacement seems to be happening. I'll smooth out the install code and do some more testing tomorrow. Looks like we're close though. |
Ookay, I think it may be better now. There was a problem with acquiring Zotero from context at startup. Pretty simple, once I figured it out. When the plugin is present at startup, we tie the processor replacement to a The problem was that immediate acquisition crashes everything at startup (ouch -- things blew up even inside a try/catch); and when I staged back to using the event, the new processor was never installed (hence the error on the term refused to go away). I think I've hit some simple incantations to handle both cases -- should be able to enable and disable the plugin and observe the results (remembering that you need to selected another style and select back to observe the change). |
Seems to be working now. But small citeproc-js bug, I think: Words in "quotes" are not being capitalized when set using Title Case. Example JSON:
|
That's been a long-standing issue. I'll take a look very soon.
…On Fri, Jan 20, 2017 at 7:43 PM, bwiernik ***@***.***> wrote:
Seems to be working now.
But small citeproc-js bug, I think: Words in "quotes" are not being
capitalized when set using Title Case. Example JSON:
{
"id": "http://zotero.org/users/1386342/items/C8XP258M",
"type": "article-journal",
"title": "From \"distance\" to \"friction\": substituting metaphors and redirecting intercultural research",
"container-title": "Academy of Management Review",
"page": "905-923",
"volume": "33",
"issue": "4",
"DOI": "10.5465/AMR.2008.34421999",
"shortTitle": "From \"distance\" to \"friction\"",
"journalAbbreviation": "AMR",
"language": "en",
"author": [
{
"family": "Shenkar",
"given": "Oded"
},
{
"family": "Luo",
"given": "Yadong"
},
{
"family": "Yeheskel",
"given": "Orly"
}
],
"issued": {
"date-parts": [
[
"2008"
]
]
}
}
]
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#2434 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AAEmSsDcAcosGCq4Gv3ZBMLBNE0N4-JOks5rUI_lgaJpZM4LkvHw>
.
|
Remove reference to nonexistent term.
(Perhaps the validator could check for these?)