question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Error encoding edge label

See original GitHub issue

OrientDB Version, operating system, or hardware.

  • v2.2.6

Operating System

  • Linux
  • MacOSX
  • Windows
  • Other Unix
  • Other, name?

Expected behavior and actual behavior

Transparently encode&decode edges’ labels

Steps to reproduce the problem

Insert an edge with a _label like /color/red. It will log a warning and then an exception like:

WARNING: $ANSI{green {db=db}} Requested command 'create edge type '%2Fcolor%2Fred' as subclass of 'E'' must be executed outside active transaction: the transaction will be committed and reopen right after it. To avoid this behavior execute it outside a transaction

javax.script.ScriptException: java.lang.IllegalArgumentException: Invalid field name 'out_%2Fcolor%2Fred'. Character '%' is invalid

NOTE:

  • Loading a dataset via gremlin API.
  • Potentially related to #5424

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:35 (17 by maintainers)

github_iconTop GitHub Comments

1reaction
MartinBrugnaracommented, Dec 6, 2016

Sorry for disappearing, but other critcal things required my attention.

I’ve now updated to the latest version: 2.2.13

But the inconsistency seams to remain. Here comes a small example with / in nodes’ attributes and edges’ labels.

The query SELECT * shows how the strings are stored escaped but also how they are returned escaped.

Using gremlin (bundeled in the installation) to query on the attributes or labels return no elements.

  • It is possible that the query arguments are escaped differently than how the data is physically stored?
  • It is semantically correct that I insert something in a database and when I query I get different values?

Thanks, Martin

** Data have been loaded with the combination of your suggestions:

echo "CREATE DATABASE PLOCAL:/srv/db ;ALTER DATABASE minimumclusters 1 ;QUIT" | "$ORIENTDB_HOME"/bin/console.sh
echo "CONNECT PLOCAL:/srv/db admin admin ;IMPORT DATABASE ${DATASET} -format=graphson ;QUIT" | time "$ORIENTDB_HOME"/bin/console.sh
1reaction
MartinBrugnaracommented, Aug 19, 2016

@smolinari you’ve already done much! Thank you =)

Read more comments on GitHub >

github_iconTop Results From Across the Web

'utf8' TextDecoder Error from 'fast-text-encoding' dependency ...
RangeError: Failed to construct 'TextDecoder': The encoding label provided ('utf8') is invalid. The issue was not reproducible on any browser ...
Read more >
utf 8 - Edge warning says "'content-type' header charset value ...
I was facing the same issue. The browser just wants you to define the mime type <link rel="stylesheet" href="styles.css" type="text/css"> ...
Read more >
Edge Dev PDF reader with wrong title encoding
If you open a pdf file with a name containing Chinese, it shows title in a wrong encoding while the link itself and...
Read more >
Solving R110Xi4 Tag Errors - VOIDS or Encoding the wrong tag
If your printer is printing VOIDS when you try to read or write to your RFID tags or encoding the wrong tag, try...
Read more >
Unicode Labels - yWorks - yFiles Knowledge Base
Set the proper encoding. Files or streams contain only bytes which have to be properly interpreted in order to treat the contents in...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found