create account

"URIError: URI malformed" error while updating a post -> How to solve by gaottantacinque

View this thread on: hive.blogpeakd.comecency.com
· @gaottantacinque · (edited)
$1.48
"URIError: URI malformed" error while updating a post -> How to solve
<center>https://images.hive.blog/DQmf5vuBHgERxoChcNNFVjwyL8McFqrGK9hmMjLQDiQdc6Y/Screen%20Shot%202020-08-09%20at%2011.08.04%20PM.png</center>

Has it ever happened to you?

You start editing a post on https://hive.blog, make a thousand changes and when you finally try to show the world what a wonderful post you put together.. it does not let you. A red nasty error saying "URI malformed" appears on top of the Update Post button and you stop and wonder why life is such a bitch. πŸ˜…πŸ˜…πŸ˜…πŸ˜…πŸ˜…πŸ˜…

This was happening on Steemit too and my finding is that it seems to happen only when you edit a post that contains emojis.

The solution is either to remove all emojis or, if you really wanna keep that beer emoji in your post <i>because it gives your post a next level meaning and you really can't live without it</i>, simply paste this script in your browser Console (Ctrl + Shift + J on Linux/Windows and Cmd + Opt + J on Mac) and it will finally let you publish your precious changes.

```
var originalEu = encodeURI;
encodeURI = (...args) => {
  try {
    return originalEu(...args);
  } catch (err) {
    console.error('Caught Error:', err);
    if (`${err}`.includes('URI malformed')) {
      console.log('Args causing issue:', ...args);
    }
  }
};
```

<br>
Hope this helps and that if someone googles that error message + "hive" they'll find this workaround.

Bear in mind though that this is a temporary solution. When you close the tab this workaround will stop working and you'll have to re-execute it the next time you come across this issue.
Maybe @quochuy will take a look at the root cause of this bug when he has a chance? πŸ™ƒπŸ™ƒπŸ™ƒπŸ™ƒπŸ™ƒ

PS. Forgot to mention, I have never seen this bug on Peakd so switching to it to publish your posts should be a solution too.

Take care πŸ˜ŽπŸ‘πŸ€

🀝
πŸ‘  , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , ,
properties (23)
authorgaottantacinque
permlinkurierror-uri-malformed-how-to-solve
categoryhive
json_metadata{"tags":["bug","hiveblog","coding","hivedev","neoxian","palnet"],"users":["quochuy"],"image":["https://images.hive.blog/DQmf5vuBHgERxoChcNNFVjwyL8McFqrGK9hmMjLQDiQdc6Y/Screen%20Shot%202020-08-09%20at%2011.08.04%20PM.png"],"links":["https://hive.blog"],"app":"hiveblog/0.1","format":"markdown"}
created2020-08-10 03:24:54
last_update2020-08-10 05:08:09
depth0
children8
last_payout2020-08-17 03:24:54
cashout_time1969-12-31 23:59:59
total_payout_value0.752 HBD
curator_payout_value0.729 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length1,781
author_reputation13,376,119,559,056
root_title""URIError: URI malformed" error while updating a post -> How to solve"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id98,988,636
net_rshares4,381,510,805,875
author_curate_reward""
vote details (36)
@gaottantacinque ·
.
properties (22)
authorgaottantacinque
permlinkre-gaottantacinque-s40y0p
categoryhive
json_metadata{"tags":["hive"],"app":"peakd/2023.10.1"}
created2023-11-12 18:58:03
last_update2023-11-12 18:58:03
depth1
children4
last_payout2023-11-19 18:58:03
cashout_time1969-12-31 23:59:59
total_payout_value0.000 HBD
curator_payout_value0.000 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length1
author_reputation13,376,119,559,056
root_title""URIError: URI malformed" error while updating a post -> How to solve"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id128,801,453
net_rshares0
@beerlover ·
<div class='pull-right'>https://files.peakd.com/file/peakd-hive/beerlover/yiuU6bdf-beerlover20gives20BEER.gif<p><sup><a href='https://hive-engine.com/?p=market&t=BEER'>View or trade </a> <code>BEER</code>.</sup></p></div><center><br> <p>Hey @gaottantacinque, here is a little bit of <code>BEER</code> from @isnochys for you. Enjoy it!</p> <p>Did you know that <a href='https://dcity.io/city</b>you can use <b>BEER</b> at dCity game</a> to buy cards to rule the world.</p> </center><div></div>
properties (22)
authorbeerlover
permlinkre-gaottantacinque-re-gaottantacinque-s40y0p-20231113t224103566z
categoryhive
json_metadata{"app":"beerlover/3.0","language":"rust","developer":"wehmoen"}
created2023-11-13 22:41:03
last_update2023-11-13 22:41:03
depth2
children0
last_payout2023-11-20 22:41:03
cashout_time1969-12-31 23:59:59
total_payout_value0.000 HBD
curator_payout_value0.000 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length493
author_reputation24,692,196,385,974
root_title""URIError: URI malformed" error while updating a post -> How to solve"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id128,833,455
net_rshares0
@beerlover ·
<div class='pull-right'>https://files.peakd.com/file/peakd-hive/beerlover/yiuU6bdf-beerlover20gives20BEER.gif<p><sup><a href='https://hive-engine.com/?p=market&t=BEER'>View or trade </a> <code>BEER</code>.</sup></p></div><center><br> <p>Hey @gaottantacinque, here is a little bit of <code>BEER</code> from @isnochys for you. Enjoy it!</p> <p>Learn how to <a href='https://peakd.com/beer/@beerlover/what-is-proof-of-stake-with-beer'>earn <b>FREE BEER</b> each day </a> by staking your <code>BEER</code>.</p> </center><div></div>
properties (22)
authorbeerlover
permlinkre-gaottantacinque-re-gaottantacinque-s40y0p-20231117t221117296z
categoryhive
json_metadata{"app":"beerlover/3.0","language":"rust","developer":"wehmoen"}
created2023-11-17 22:11:18
last_update2023-11-17 22:11:18
depth2
children0
last_payout2023-11-24 22:11:18
cashout_time1969-12-31 23:59:59
total_payout_value0.000 HBD
curator_payout_value0.000 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length528
author_reputation24,692,196,385,974
root_title""URIError: URI malformed" error while updating a post -> How to solve"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id128,953,185
net_rshares0
@isnochys ·
Thank you for your [witness vote](https://hivesigner.com/sign/account-witness-vote?witness=isnochys&approve=1)!
 Have a !BEER on me!
To Opt-Out of my witness beer program just comment STOP below
properties (22)
authorisnochys
permlinkre-re-gaottantacinque-s40y0p-20231113t224045z
categoryhive
json_metadata"{"app": "beem/0.24.26"}"
created2023-11-13 22:40:51
last_update2023-11-13 22:40:51
depth2
children0
last_payout2023-11-20 22:40:51
cashout_time1969-12-31 23:59:59
total_payout_value0.000 HBD
curator_payout_value0.000 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length194
author_reputation48,908,785,519,137
root_title""URIError: URI malformed" error while updating a post -> How to solve"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id128,833,452
net_rshares0
@isnochys ·
Thank you for your [witness vote](https://hivesigner.com/sign/account-witness-vote?witness=isnochys&approve=1)!
 Have a !BEER on me!
To Opt-Out of my witness beer program just comment STOP below
properties (22)
authorisnochys
permlinkre-re-gaottantacinque-s40y0p-20231117t221104z
categoryhive
json_metadata"{"app": "beem/0.24.26"}"
created2023-11-17 22:11:06
last_update2023-11-17 22:11:06
depth2
children0
last_payout2023-11-24 22:11:06
cashout_time1969-12-31 23:59:59
total_payout_value0.000 HBD
curator_payout_value0.000 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length194
author_reputation48,908,785,519,137
root_title""URIError: URI malformed" error while updating a post -> How to solve"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id128,953,170
net_rshares0
@gitplait ·
Upvoted by GITPLAIT!

We have a curation trial on Hive.vote. you can earn a passive income by delegating to [@gitplait](https://hive.vote/dash.php?i=15&id=1&user=gitplait)
We share 80 % of the curation rewards with the delegators.
___

_To delegate, use the links or adjust_ [10HIVE](https://hivesigner.com/sign/delegateVestingShares?delegator=&delegatee=gitplait&vesting_shares=10%20HP), [20HIVE](https://hivesigner.com/sign/delegateVestingShares?delegator=&delegatee=gitplait&vesting_shares=20%20HP), [50HIVE](https://hivesigner.com/sign/delegateVestingShares?delegator=&delegatee=gitplait&vesting_shares=50%20HP), [100HIVE](https://hivesigner.com/sign/delegateVestingShares?delegator=&delegatee=gitplait&vesting_shares=100%20HP),   [200HIVE](https://hivesigner.com/sign/delegateVestingShares?delegator=&delegatee=gitplait&vesting_shares=200%20HP), [500HIVE](https://hivesigner.com/sign/delegateVestingShares?delegator=&delegatee=gitplait&vesting_shares=500%20HP), [1,000HIVE](https://hivesigner.com/sign/delegateVestingShares?delegator=&delegatee=gitplait&vesting_shares=1000%20HP), [10,000HIVE](https://hivesigner.com/sign/delegateVestingShares?delegator=&delegatee=gitplait&vesting_shares=10000%20HP), [100,000HIVE](https://hivesigner.com/sign/delegateVestingShares?delegator=&delegatee=gitplait&vesting_shares=100000%20HP)

___

Join the [Community](https://hive.blog/trending/hive-103590) and chat with us on [Discord](https://discord.gg/CWCj3rw)  let’s solve problems & build together.
πŸ‘Ž  
properties (23)
authorgitplait
permlinkqeuyqp
categoryhive
json_metadata{"links":["https://hive.vote/dash.php?i=15&id=1&user=gitplait","https://hivesigner.com/sign/delegateVestingShares?delegator=&delegatee=gitplait&vesting_shares=10%20HP","https://hivesigner.com/sign/delegateVestingShares?delegator=&delegatee=gitplait&vesting_shares=20%20HP","https://hivesigner.com/sign/delegateVestingShares?delegator=&delegatee=gitplait&vesting_shares=50%20HP","https://hivesigner.com/sign/delegateVestingShares?delegator=&delegatee=gitplait&vesting_shares=100%20HP","https://hivesigner.com/sign/delegateVestingShares?delegator=&delegatee=gitplait&vesting_shares=200%20HP","https://hivesigner.com/sign/delegateVestingShares?delegator=&delegatee=gitplait&vesting_shares=500%20HP","https://hivesigner.com/sign/delegateVestingShares?delegator=&delegatee=gitplait&vesting_shares=1000%20HP","https://hivesigner.com/sign/delegateVestingShares?delegator=&delegatee=gitplait&vesting_shares=10000%20HP","https://hivesigner.com/sign/delegateVestingShares?delegator=&delegatee=gitplait&vesting_shares=100000%20HP","https://hive.blog/trending/hive-103590","https://discord.gg/CWCj3rw"],"app":"hiveblog/0.1"}
created2020-08-10 17:18:30
last_update2020-08-10 17:18:30
depth1
children0
last_payout2020-08-17 17:18:30
cashout_time1969-12-31 23:59:59
total_payout_value0.000 HBD
curator_payout_value0.000 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length1,493
author_reputation911,220,543,569
root_title""URIError: URI malformed" error while updating a post -> How to solve"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id98,998,977
net_rshares-6,712,903,482
author_curate_reward""
vote details (1)
@quochuy ·
Thank you, I've raised a ticket:
https://gitlab.syncad.com/hive/condenser/-/issues/81
properties (22)
authorquochuy
permlinkqeu561
categoryhive
json_metadata{"links":["https://gitlab.syncad.com/hive/condenser/-/issues/81"],"app":"hiveblog/0.1"}
created2020-08-10 06:39:39
last_update2020-08-10 06:39:39
depth1
children1
last_payout2020-08-17 06:39:39
cashout_time1969-12-31 23:59:59
total_payout_value0.000 HBD
curator_payout_value0.000 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length85
author_reputation721,992,639,222,957
root_title""URIError: URI malformed" error while updating a post -> How to solve"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id98,990,344
net_rshares0
@gaottantacinque · (edited)
Awesome, thanks @quochuy!

Just checked it, the error is actually only editing a post with an emoji, not creating it.  

I cannot always reproduce it though. For instance if I edit this post all is fine.

I can still reproduce it on this post though: https://hiveblocks.com/bitcoin/@gaottantacinque/the-moment-you-find-out-your-btc-bip38-passphrase-does-not-work

In the latter please ignore the extra `<i>` around the emojis. The first time using those it allowed me to publish my edits but it worked only the first time. Then I had to use my hack to swallow the error.

πŸ‘
properties (22)
authorgaottantacinque
permlinkqeu70t
categoryhive
json_metadata{"users":["quochuy"],"app":"hiveblog/0.1","links":["https://hiveblocks.com/bitcoin/@gaottantacinque/the-moment-you-find-out-your-btc-bip38-passphrase-does-not-work"]}
created2020-08-10 07:19:42
last_update2020-08-10 07:23:57
depth2
children0
last_payout2020-08-17 07:19:42
cashout_time1969-12-31 23:59:59
total_payout_value0.000 HBD
curator_payout_value0.000 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length573
author_reputation13,376,119,559,056
root_title""URIError: URI malformed" error while updating a post -> How to solve"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id98,990,685
net_rshares0