Rabbi Yose son of Rabbi Hanina said: a gentile who observed the Sabbath before he accepted circumcision is liable to death. Why? Because he was not commanded concerning it and does not observe it properly. And what did you see to say that one who observed the Sabbath is liable to death? Rabbi Hiyya bar Abba said: it is the way of the world that when a king and a queen are sitting and conversing with one another, whoever comes and thrusts his head between them is liable to death. So too the Sabbath is a sign between the Holy One, blessed be He, and Israel, as it says, "between Me and the children of Israel it is a sign." Therefore a gentile who comes and thrusts himself between them is liable to death. Everything I have declared abominable to you is included in "you shall not eat," as it says, "you shall not eat any abominable thing" (Deuteronomy 14:3). If so, let the products of forbidden Sabbath labor be prohibited. The verse states, "for it is holy to you": it is holy, but its products are not holy.
The Sabbath as the Private Sign Between God and Israel
Yalkut Shimoni on Torah 391:4
אָמַר רַבִּי יוֹסֵי בְּרַבִּי חֲנִינָא. כּוּתִי שֶׁשָּׁמַר אֶת הַשַּׁבָּת עַד שֶׁלֹּא קִבֵּל אֶת הַמִּילָה, חַיָּב מִיתָה. לָמָּה, שֶׁלֹּא נִצְטַוָּה עָלֶיהָ וְאֵינוֹ מְשַׁמֵּר אוֹתָהּ כְּתִקְּנָהּ. וּמָה רָאִיתָ לוֹמַר, מִי שֶׁשָּׁמַר אֶת הַשַּׁבָּת חַיָּב מִיתָה. אָמַר רַבִּי חִיָּא בַּר אַבָּא. בְּנֹהַג שֶׁבָּעוֹלָם מֶלֶךְ וּמַטְרוּנָא שֶׁיּוֹשְׁבִין וּמְשִׂיחִין זֶה עִם זֶה, מִי שֶׁבָּא וּמַכְנִיס רֹאשׁוֹ בֵּינֵיהֶם אֵינוֹ חַיָּב מִיתָה, כָּךְ הַשַּׁבָּת הִיא [אוֹת] בֵּין הַקָּדוֹשׁ בָּרוּךְ הוּא וּבֵין יִשְׂרָאֵל שֶׁנֶּאֱמַר בֵּינִי וּבֵין בְּנֵי יִשְׂרָאֵל אוֹת הִיא, לְפִיכָךְ כּוּתִי שֶׁבָּא וּמַכְנִיס עַצְמוֹ בֵּינֵיהֶם חַיָּב מִיתָה. כָּל שֶׁתִּעַבְתִּי לְךָ הֲרֵי הוּא בְּבַל תֹּאכַל, שֶׁנֶּאֱמַר (דברים יד, ג) "לֹא תֹאכַל כָּל תּוֹעֵבָה". אִי הָכִי מַעֲשֵׂה שַׁבָּת לִיתְסְרוּ. אֲמַר קְרָא, כִּי קֹדֶשׁ הִיא לָכֶם, הִיא קֹדֶשׁ וְאֵין מַעֲשֶׂיהָ קֹדֶשׁ.