New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@rmlio/yarrrml-parser

Package Overview
Dependencies
Maintainers
2
Versions
50
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@rmlio/yarrrml-parser - npm Package Compare versions

Comparing version 1.2.0 to 1.2.1

test/csv-delimiter/semicolon/data.txt

11

CHANGELOG.md

@@ -10,2 +10,12 @@ # Changelog

## [1.2.1] - 2020-09-04
### Fixed
- Fix docker build command in README (see [issue 91](https://github.com/RMLio/yarrrml-parser/issues/91))
- Test example5 is invalid YARRRML (see [issue 93](https://github.com/RMLio/yarrrml-parser/issues/93))
- Mapping TSV files (see [issue 95](https://github.com/RMLio/yarrrml-parser/issues/95))
### Changed
- Update dev deps
## [1.2.0] - 2020-08-17

@@ -182,2 +192,3 @@

[1.2.1]: https://github.com/RMLio/yarrrml-parser/compare/v1.2.0...v1.2.1
[1.2.0]: https://github.com/RMLio/yarrrml-parser/compare/v1.1.1...v1.2.0

@@ -184,0 +195,0 @@ [1.1.1]: https://github.com/RMLio/yarrrml-parser/compare/v1.1.0...v1.1.1

53

lib/rml-generator.js

@@ -112,8 +112,51 @@ /**

if (!source.type) {
this.quads.push(quad(
sSubject,
namedNode(namespaces.rml + 'source'),
literal(source.access)
));
if (source.referenceFormulation === 'csv' && source.delimiter !== undefined && source.delimiter !== ',') {
// We need CSVW.
this.prefixes['csvw'] = namespaces.csvw;
const csvwSubject = namedNode(this.baseIRI + this.getUniqueID('csvw'));
const dialectSubject = namedNode(this.baseIRI + this.getUniqueID('csvw-dialect'));
this.quads.push(quad(
sSubject,
namedNode(namespaces.rml + 'source'),
csvwSubject
));
this.quads.push(quad(
csvwSubject,
namedNode(namespaces.rdf + 'type'),
namedNode(namespaces.csvw + 'Table')
));
this.quads.push(quad(
csvwSubject,
namedNode(namespaces.csvw + 'url'),
literal(source.access)
));
this.quads.push(quad(
csvwSubject,
namedNode(namespaces.csvw + 'dialect'),
dialectSubject
));
this.quads.push(quad(
dialectSubject,
namedNode(namespaces.rdf + 'type'),
namedNode(namespaces.csvw + 'Dialect')
));
this.quads.push(quad(
dialectSubject,
namedNode(namespaces.csvw + 'delimiter'),
literal(source.delimiter)
));
} else {
this.quads.push(quad(
sSubject,
namedNode(namespaces.rml + 'source'),
literal(source.access)
));
}
if (source.iterator) {

@@ -120,0 +163,0 @@ this.quads.push(quad(

@@ -255,2 +255,11 @@ /**

});
describe('csv delimiter', () => {
it('tab', function (done) {
work('csv-delimiter/semicolon/mapping.yarrrml', 'csv-delimiter/semicolon/mapping.rml.ttl', done);
});
it('semicolon', function (done) {
work('csv-delimiter/tab/mapping.yarrrml', 'csv-delimiter/tab/mapping.rml.ttl', done);
});
});
});

@@ -257,0 +266,0 @@

4

package.json
{
"name": "@rmlio/yarrrml-parser",
"version": "1.2.0",
"version": "1.2.1",
"description": "Parse YARRRML descriptions into RML RDF statements",

@@ -36,3 +36,3 @@ "main": "lib/yarrrml2rml.js",

"devDependencies": {
"mocha": "^8.0.1"
"mocha": "^8.1.3"
},

@@ -39,0 +39,0 @@ "bin": {

@@ -78,3 +78,3 @@ # YARRRML Parser

```bash
docker build -t umids/yarrrml-parser .
docker build -t yarrrml-parser .
```

@@ -81,0 +81,0 @@

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc